No, there shouldn't. How would an applet call back to the correct hostif you
have it mounted from localhost? Applets are only allowed to get resources
from their own server.
Your fundamental error in thought is that applets are not at all like CSS..
CSS is a brower-interpreted, client-side phenomenon. Applets are a JVM-run,
server-side phenomenon that just happen to run out of a browser. Big difference.
Now stop whining about your pathetic thoughts of how things "should" be and
deal with reality as it actually is, or find a profession that doesn't require
rational reasoning. Or write your own technology to compete with applets.
Just stop whining over and over and over and over and over and over abouthow
you think in your infinite wisdom and genius that things should be different
than they actually are. You'll never get the job done that way.
It's pathetic.
Guys, sorry, but you're completely nuts. Once more I understand why
Java has got the reputation of being bloated. We should remember that
Java is not necessarily targeted only at big corporations and multi-
million projects! The OP asked how to do a certain thing. Telling him
how a Fortune 500 company should do it is not going to help him.
Besides, I don't think even a Fortune 500 company should clone the
whole production server just to test one *applet*!
To answer directly to the OP question: there are a few ways you can
test your own modified applet against your production server.
1) you can run the applet as a standalone application: either coding
(e.g. a JFrame to contain it) or using something like Oracle's
AppletViewer. This is feasible only if the applet does not interact
with the surrounding page.
2) signed applets can bypass security restrictions. So you can run
your (signed) applet on a page loaded from localhost and still connect
to the remote server. Or, if you *really* need the applet to run on
the production page itself, you can probably use something like
Greasemonkey to patch (your client-local version of) the page to
include the applet. Needless to say, the latter option could be a
violation of the site's terms of use, and it's unnecessarily
cumbersome, so avoid it unless it's the only option left.
To everyone else: applets *are* client-side. Really, I can't imagine
why you think otherwise. Yes, they are downloaded from a server; so
what? Most software nowadays is downloaded from somewhere the first
time. But they run on the client, and only talk to the server via
remoting, RPC, SOAP or whatever else. Or do you really believe that
e.g. Flash is server-side?
Sorry for being a little aggressive, but I can't really understand why
there are ~50 posts sponsoring the big costly solution and ~0
suggesting the practical one.
Cheers,
Alessio