SCRIPT_NAME is a server side path, try REQUEST_URI. This includes the query
string but it's easy to remove.

Elbert
http://swiftlet.org


On Thu, Feb 16, 2012 at 8:27 AM, Donovan Brooke <li...@euca.us> wrote:

> Hello,
>
> What is the best way to get the /somedir/ values in the request URI?
>
> I tried
> $t_pathinfo = $_SERVER['PATH_INFO'];
>
> but was given an error of undefined index. After looking at the docs, it
> appears the error derives from something I may have to do in the .ini file.
>
> However, is there a standard/better way of grabbing the info after the
> host and before the query string.. perhaps 'SCRIPT_NAME'?
>
> Thanks!
>
> Donovan
>
>
>
>
> --
> D Brooke
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

Reply via email to