开发者

I am passing an external link(site link) in url and also i decoded it?it works in windows,but not in linux?

I am passing an external link in url as shown below,

http://livedirectory/user/http://www.google.com

i decoded http://www.google.com it works in windows,

but in linux its not working y??

i used urlencode,utf8_encode,it works in windows

http://livedirectory/user/`http://www.google.com` the开发者_StackOverflow中文版 http://www.google.com is encoded

but in bluehost server,the http://www.google.com is not encoded,i dont know y,how to encode in linux server Mr.pekka....


You are not giving enough detail to give a complete answer, but speaking in general, that is not a valid URL. You need to percent encode the second URL:

http://livedirectory/user/http%3a%2f%2fwww.google.com

in PHP, the function for that is urlencode().

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜