PHP - iPhone send full URL into REQUEST_URI

浪尽此生 提交于 2020-01-15 09:31:12

问题


I have a problem with my router. It is producing many Error404 because of invalid variable $_SERVER['REQUEST_URI']. Normally REQUEST_URI is in format /your-event/buy/ but in logs it always contains full URL like http://domain.com:80/your-event/buy/ and if there is this, REFERRER is always http://m.facebook.com and HTTP_USER_AGENT is iPhone

Is it bug of router or what? I can see many orders made on iPhone, but also lots of those errors in log. I think that REQUEST_URI should't contains whole URL. Btw, I'm using really simple AltoRouter (http://altorouter.com/)


回答1:


http://domain.com:80 is nothing but website running in port 80 since it is http request and http://domain.com:443 if url refers to https

and

http://domain.com:80 and http://domain.com both are same, you can use https://www.google.com:443 or simply https://www.google.com



来源:https://stackoverflow.com/questions/41665675/php-iphone-send-full-url-into-request-uri

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!