7/13/2010 10:38:29 PM
Title:
save the selected file into the destination location.
I'm trying to Upload the File from Client PC into the server PC location.
I'm using the below code to browse the File.
var fileRefernce:FileReference= new FileReference();
fileRefernce.browse();
Want the selected to files to be in <IP Address>:/DestinationFolder of the server PC .
Previously I have used to Servlets .Is their any way to acheive the same thru Flex code.
Please help me in acheiving the same .
7/13/2010 11:26:58 PM
flex code is client side just like html, so it cannot execute on server and save file on server itself. You need to use some server script like asp, php, java etc as you were using earlier. Flex code can just browse and send the file back to some server script but cannot save the file directly.
7/13/2010 11:31:10 PM
flash or flex can never save file to server , you can use a server language like php to save file on server. Flex makes request to server page which saves the file on server
see this links for saving file on server
http://www.sephiroth.it/tutorials/flashPHP/amfphp_bytearray/index.php
http://www.zedia.net/2008/sending-bytearray-and-variables-to-server-side-script-at-the-same-time/
7/14/2010 9:18:35 PM
think the flash / flex application like html, it works when reaches the client browser, so it can just pass the bytestream of uploaded file to server but cannot save it. You need to use server code to assist your flash application and save the file on server