1.
My
browser is IE 6.0
and
OS is windows 2000 professional
2.
The attachment dialog box shows correct filename.
Also saving the file to my local disk also is correct
But when i try to open the file directly on clik of "open" button from
dialog box, the name is %xx
3.
>>fileName = new String(fileName.getBytes("ISO-8859-1"), "UTF-8");
I have done my jsp page encoding as UTF-8 but i suppose my JVM or server
specific encoding is ISO-8859-1
I need to do String = new String(String.getBytes("ISO-8859-1"), "UTF-8");
before storing anything to the oracle database
otherwise it appears junk whenever i try to get it on the screen
Thanks and Regards,
Kapil Sharma
IAP Company Ltd.
-----Original Message-----
From: Antonio Petrelli [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 08, 2007 4:21 PM
To: Struts Users Mailing List
Subject: Re: FileName characters.
2007/5/8, Kapil Sharma <[EMAIL PROTECTED]>:
>
> Hii
>
> I am using struts, jboss 4.0.1 and downloading file from the JSP as an
> atachment..
>
> My file has japanese and chinese characters...
>
> The problem is that when i m directly opening this file on the fly from
> the
> Dialog box by clicking on the open button, it is showing me some
> characters
> like %3s or something like.
Do you mean in the browser?
The %xx characters are special characters encoded for URLs.
By the way, what's your browser/operating system?
These characters are appearing file on the dialog box and also saving the
> file is OK but i don't know why they get something like while opening on
> the
> fly
Sorry, I can't understand. The opened file has the correct filename or not?
And the saved file?
> try {
>
> fileName = new String(fileName.getBytes("ISO-8859-1"), "UTF-8");
Why do you get bytes as ISO-8859-1 and reencode them as UTF-8? It does not
make sense!
Antonio
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]