Chinese chars on URL parameters

Hi Guys,

I need to solve a small issue I have for a project I am doing now. The project is for an Asian company and we have to include ASIAN characters on URL, like the following: http://www.eztable.com.tw/search.php?city=台北市&tag_family=餐廳排行榜&tag=商務聚餐&date=2012-07-04&people=2

I am not familiar at all with this, could you help me out? It seems that is simply encoded but when I try to do it, the URL is not converted to Chinese chars (the above URL is displayed as the attached image and thats what my client wants)

2991

Screen Shot 2012-07-02 at 2.22.04 PM.png

Any help would be highly appreciated

Hi,

the url you provide, the website contain all link in chinese and on hover it pass request parameter in chinese as specified in anchor tag, so i don’t think they use any encode method.

they provide chinese anchor tag( might directly typed from chinese language keyboard ).

and gr8 to see you here… :)

What do you mean? They do not use any encode and the browser will automatically display the chars? I am not familiar at all to work with asian languages.

PS: 2muchwork… unable to be as much as i would love to

Hi,

as I also not so much aware with development in Asian language, I had work only with English.

I don’t know you want to encode the url or not.

– But here is demo what I had do to pass chinese char in url and get by Request method.

On redirect I use this code,


..

..

$this->redirect(array('admin','tag_family'=>'餐廳排行榜'));

and on echo the specified request I got the chinese character word as request,


public function actionAdmin()

{

	echo $_REQUEST['tag_family'];

the out put shows : 餐廳排行榜

to see example you can also saw Yii forum chinese community posts for idea.

I use Dreamweaver to save file, as when I tried with Eclipse it not save file as chinese characters specified in file.

Thank you so much… you were right, in order to display the parameters in Chinese or any other asian language, we do not need to encode it… customer wanted to beautify the URL with its language. I am not using the parameter at all for any operation on my code so I believe I am on the safe line.

Cheers and thanks! +1 for your kindness

Welcome anytime… :rolleyes: