karthikeyan_coder Posted January 16, 2007 Share Posted January 16, 2007 hello,i have an urlfor examplehttp://xxx.xxx.222.22/helpdesk/cp/login.php?PHPSESSID=672bbd0810bbdf4c3adb149201736dedif i am in login.php then i need $current;$current == /cp/login.phpi am in IIS.. so you know that $_SERVER['DOCUMENT_ROOT']; wont workand one more clue is... i need a string that comes after first "/helpdesk" and before first "?"if url ishttp://xxx.xxx.222.22/helpdesk/cp/cann/add.php?PHPSESSID=672bbd0810bbdf4c3adb149201736dedthen $current == "/cp/cann/add.php"any ideas? thanks in advance :) Quote Link to comment Share on other sites More sharing options...
trq Posted January 16, 2007 Share Posted January 16, 2007 [quote]i am in IIS.. so you know that $_SERVER['DOCUMENT_ROOT']; wont work[/quote]That makes no sense.Take a look at [url=http://php.net/parse_url]parse_url[/url]. Quote Link to comment Share on other sites More sharing options...
karthikeyan_coder Posted January 16, 2007 Author Share Posted January 16, 2007 thanks for parse_url ...Posted by mistake Document_root Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.