File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes about encoding a chinese character in url Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "about encoding a chinese character in url" Watch "about encoding a chinese character in url" New topic
Author

about encoding a chinese character in url

BiBi Chan
Greenhorn

Joined: Jul 08, 2013
Posts: 2
Help ~
i was unable to encode a chinese char cause it reply me other words.



It output is different when encoded.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

Regardless of what characters are in your URL parameters, you should always URL-encode them. They might contain an equals sign or an ampersand, for example, which would lead to confusion. That's why URL-encoding exists. So like this:

BiBi Chan
Greenhorn

Joined: Jul 08, 2013
Posts: 2
which mean i have to encode all?
Darryl Burke
Bartender

Joined: May 03, 2008
Posts: 4523
    
    5

Yup.


luck, db
There are no new questions, but there may be new answers.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: about encoding a chinese character in url
 
Similar Threads
how to send email from j2me using Servlets
any Idea about the new new javax.net.ssl.HttpsURLConnection
SMS API for swing Application
Passing Information Between Web Applications (Alternative to Web Services)
not able to open url connection in java and getting certification error