Re: How to get the URL into a var?
| From: | bvr | Date: | Mon, 04 Feb 2002 16:53:01 +0000 |
| Subject: | Re: How to get the URL into a var? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-83423@lists.php.net to get a copy of this message | ||
You can get the requested location from:
$_SERVER["QUERY_STRING"]
and use the dirname() function on it.
bvr.
On Sat, 2 Mar 2002 10:29:09 +0100, Andy wrote:
>Hi there,
>
>I am trying to find out which dir the user is browsing. How can I get the
>URL into a var? I tryed path_info, but it only returns the filename.
>
>Here is an example:
>
>URL: http://www.server.com/subapp/test.php
>
>Should return :
>
>subapp
>
>Is this possible??
>
>Thanx for any help
>
>Cheers Andy
>
>
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
>For additional commands, e-mail: php-general-help@lists.php.net
>To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
>