This week's book giveaway is in the OCAJP forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide 1Z0-808 and have Jeanne Boyarsky & Scott Selikoff on-line! See this thread for details.
Ive been the forum for a solution to this problem but couldnt find one, I hope you can help.
I am trying to run a socket client within an applet. I got the applet connecting to the serversocket when the serversocket is run on the same machine as the applet. I read that to connect remotely to the applet and have the serversockets work the applet has to be run on the same machine as the socket is hosted from and that all applet clients will have to download the .policy file.
Is there any way around this? Basically I would like to host the applet from a seperate webserver and have it connect to the serversocket on a different machine and still allow people to run the applet remotely.
If I sign the applet will this allow me to achieve this?
In theory you can use a signed applet for that. In practice this is almost always more trouble than it's worth and the requirements are better served by not using an applet at all but a full blown application distributed through JavaWebStart (for example).
Joined: May 16, 2003
Thanks for the suggestion,
I have never used Java Web Start. I gather that every client would need to access the application through Java Web Start, and thus need it on their machine?
Joined: Oct 12, 2000
Java WebStart is installed with the JRE so you don't need to specifically install is.