JAVA applet help - someone who knows about webpages

Just a short question,

when you put a java applet into a website, if that java appletsaves and loads files, where does it save and load them from?

does it save on the persons computer who is using the applet or does it save to some directory within the webpage? If so how is this done?

thnx

[315 byte] By [Chrisdigitya] at [2007-11-27 9:15:14]
# 1
> Just a short question,> when you put a java applet into a website, if that> java appletsaves and loads files, where does it save> and load them from?Depends on the implementation. In general, applets cannot access the client's file system though.
warnerjaa at 2007-7-12 22:04:08 > top of Java-index,Java Essentials,Java Programming...
# 2
so if the files save in the webpage, how do you access them
Chrisdigitya at 2007-7-12 22:04:08 > top of Java-index,Java Essentials,Java Programming...
# 3

Applets are not permitted to acces files on the client machine (I mean, would you want someone else's web page messing with your files).

So any data they load or save has to come from, or go to the server from which they are loaded.

Applets can use URL based connections to read data from the server, or send data (providing there is server side code to receive it).

malcolmmca at 2007-7-12 22:04:08 > top of Java-index,Java Essentials,Java Programming...
# 4
so if i was the owner of a website that saved files to a server, how would i then acces them files from my computer.
Chrisdigitya at 2007-7-12 22:04:08 > top of Java-index,Java Essentials,Java Programming...
# 5
use a url to access files on a server?
mkoryaka at 2007-7-12 22:04:08 > top of Java-index,Java Essentials,Java Programming...
# 6

> so if i was the owner of a website that saved files

> to a server, how would i then acces them files from

> my computer.

Depends how your server software stores them. It's more usual, actually, for a webserver to store incoming data in a database (in particular because you have to allow for talking to serveral clients at once.)

In any case any data uploaded needs to be handled by a Servlet on the server, and you must write that Servlet to store the incoming data in an appropriate place.

malcolmmca at 2007-7-12 22:04:08 > top of Java-index,Java Essentials,Java Programming...