title: How to upload file from local client machine to FTP using JSP and servlet? How to give url address of the file on FTP in html to view them in browser?
body: <p>I want to develop a file upload utility using JSP and servlet. In this a user can upload any file, size ranging from few MB's to few hundred MB's. 
  This utility contains a regular form designed using html in a jsp file.
  when this form is submitted the selected file on given local client machine path is get uploaded with the help of called servlet.</p>
  
  <p>The twist is here I want to upload my files directly from client local machine to FTP server. This FTP server may be on different machine or may be on same machine where my web server and db server is situated.</p>
  
  <p>I searched on internet for guidance but I found the code which uploads files from local client machine to webserver. 
  Or from webserver local path to FTP server. I dint found such tutorial which uploads files from local client machine to directly FTP server.
      I want to ask expert is there any way to achive above goal i.e. uploading file from client machine to FTP server directly using jsp servlet.</p>
  
  <p>I need some or complete reference code for the same.</p>
  
  <p>I have another question in which user will see the list of uploaded file names in hyper link form. I can do this part. 
  When user clicks on these hyperlink he can see the file in different browser window. But the twist is the showed file will come from above FTP. So the question is how to give the url of file on FTP in the above hyperlink. Because to access the file from FTP we need to give its host address, username, password and port number. How to achive this task.</p>
  
  <p>Friends please guide me in these issues</p>
  
  <p>Thanks You!</p>