wood burning stoves 2.0*
The moose likes JSP and the fly likes special charecters in file name while downloading. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "special charecters in file name while downloading." Watch "special charecters in file name while downloading." New topic
Author

special charecters in file name while downloading.

Khader mohammed
Greenhorn

Joined: Apr 26, 2007
Posts: 2
Hi,

I have a jsp to download files.I get the "page cant be displayed error" if the file name contains the # charecter.

Can some one please suggest the solution.

Thanks in Advance.

Khader.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60050
    
  65

The octothorpe (pound sign) character is a reserved character within a URL (just like ? and &). Be sure that you are URL-encoding your URL components.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Khader mohammed
Greenhorn

Joined: Apr 26, 2007
Posts: 2
Thanks for the reply.
I tried with java.net.URLEncoder.encode() along with using charset as UTF-8.
But now nothing downloads.

Kindly suggest what are steps need to solve this problem.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60050
    
  65

Originally posted by Khader mohammed:
Kindly suggest what are steps need to solve this problem.


Please read this. Can't say much more without details.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: special charecters in file name while downloading.
 
Similar Threads
hey guys
please help me out.. exam tomorrow
How to I know the my URLyBird version?
FTP
how to make a war file