I am trying to create a html page based on data I obtain from an applet, and store this page on the server, where the applet is running from. It works when I test it locally on my own machine, but when I try it live, online, it dosnt seem to create the page.
The (edited) code I use to create the page is as follows:
The execution of the code dosnt seem to go into the try. It just stops there. I set all the permissions on the folders required to #777 Perhaps its not possible to use a buffered writer in this manner? Ive been trying a few things with URI references instead of file objects but Im not having much luck there.
Any help greatly appreciated. Thank you,
Eoin. [ July 04, 2007: Message edited by: Eoin Mac Aoidh ]
Thanks Ulf, I dont think its a security problem, the applet is signed. It seems to be something else. Thamks for the I/O exception tip. - Ill work on that. I just threw the try/catch clause together quickly for the sake of creating a coherent post.
Joined: Mar 22, 2005
I just noticed you're trying to construct the file name from "AppletCodebase" - if that's what the getCodeBase method returns, it can't possibly work, because if run on a web server it would be an HTTP URL (and there'd definitely be an IOException thrown).
Oh, and any file the applet writes would of course be created on the client, not on the server. [ July 04, 2007: Message edited by: Ulf Dittmer ]
Eoin Mac Aoidh
Joined: May 19, 2005
Thanks again Ulf. I was trying to use the getCodeBase method, running on a webserver and I was also trying to create the file on the server, not the client but I guess thats just not possible... Ive worked around it though and created a file on the client. Its not quite what I wanted, but it will do! thanks for your pointers.