• Post Reply Bookmark Topic Watch Topic
  • New Topic

Urgently Need Help.....  RSS feed

 
Ray Gear
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to use JSP and Servlet for my file upload, then file transfer(ftp) to ftp server.... i can't use 3rd party package.....
 
Piter john
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Then Whts your actual Problem ?
write in detail
 
Peter Daly
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are a few free file upload components available. Do you have a legit reason for needing to develop your own, or is it the not-invented-here syndrome.
When at all possible, don't reinvent the wheel, for a variety of reasons.
-Pete
 
Phil Chuang
Ranch Hand
Posts: 251
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's actually not that difficult to do, in theory.
I have done it in practice, but I don't have the code on me.
When transmitting a file via form, the form type has to be an enc/multipart (research for exact type name). The problem lies in that HttpServletRequest is not built to handle it, so you have to process the request object yourself before you can get any of the data. If you look on o'reilly's site, or do some googling, you should be able to find some code on how to do this. I will try and get the code I developed and post it here later.
 
Andy Bowes
Ranch Hand
Posts: 171
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Go to here o-Reilly Servlet classes to download a standard set of classes to handle multipart requests.
 
Ray Gear
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well... i'm working on an industrial proj... that's why i can't possibly use any 3rd party package.... i have to use pure java.
use java as bean, jsp to use the bean.
in the java code itself, i need to use the ftp command, but have limited command - PUT, CD, QUIT, FTP...
ftp server at a remote end.
so wonder if anyone can help
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!