LittleWing
Programmer
Alright boyz and girls, here one to get you thinking.
The issue
I have a servlet to process a request. This request generates a flat file as output. I want to place the flat file on the users machine in a shared folder. Note, this machine will always be part of the LAN.
The usual excuse
The code i wrote works perfectly on my own machine, writing to my machine, but when executing on the server, trying to write to my machine, it fails.
FileOutputStream out = new FileOutputStream( "\\\\" + request.getRemoteAddr() + "\\download\\contacts.txt"
;
I also tried using the machine name instread of the IP address but to no avail.
So, what i really want to know is this: does this sort of file naming work? Any suggestions??
The issue
I have a servlet to process a request. This request generates a flat file as output. I want to place the flat file on the users machine in a shared folder. Note, this machine will always be part of the LAN.
The usual excuse
The code i wrote works perfectly on my own machine, writing to my machine, but when executing on the server, trying to write to my machine, it fails.
FileOutputStream out = new FileOutputStream( "\\\\" + request.getRemoteAddr() + "\\download\\contacts.txt"
I also tried using the machine name instread of the IP address but to no avail.
So, what i really want to know is this: does this sort of file naming work? Any suggestions??