2013-04-11 28 views
2

我有問題,A HREF鏈接和引號HTML與問號

我應該產生這樣的

<a class="vk_share__a" href = "http://vk.com/share.php?url=http://vita-plant.ru<?=$arResult["DETAIL_PAGE_URL"] ?>&title=<?=$arResult[NAME]?>&description=<?=$arResult[PREVIEW_TEXT]?>&image=http://vita-plant.ru<?=$social_img_link;?>" id="vk_share_button<?=$social_id?>"></a> 

鏈接當我檢查,並雙擊它,在Chrome開發者工具它的href鏈接工作正確,與cyrillyc信

<a href="http://vk.com/share.php?url=Привет мир" title="">клик</a> 

,但是當我將鼠標懸停和點擊頁面上的得到這樣的

http://vk.com/share.php?url=%CF%F0%E8%E2%E5%F2%20%EC%E8%F0 

當我需要

http://vk.com/share.php?url=Привет%20мир 

enter image description here

我怎樣才能在Chrome開發者工具和懸停點擊事件cyryllic信?

MB它的PHP mod_rewrite或htaccess?

謝謝!

+0

我建議你閱讀有關unicodes:joelonsoftware.com/articles/Unicode.html – 2013-04-11 15:29:06

回答

1

這實際上工作正常。

URL不能包含非ASCII字符,因此西里爾文正在被瀏覽器轉換爲punycode以確保其正確。