Jason ML wrote:
> Hi PHP'ers,
>
> PHP 4.4.8 and 5.
>
> say I have a url like:
>
> http://www.mydomain.tld/jason/index.php
>
> In that index.php I want to have a piece of code that runs that tells
> me the 'jason' part of the URL so that I can run some custom read only
> queries for 'jason'
>
Your original post has this as the URL:
> http://www.mydomain.tld/jason/index.php
That's why I gave you that command.
If you want jason out of what you posted,
Check out the following commands:
http://us.php.net/array_pop
http://us.php.net/explode
Thank you,
Micah Gersten
onShore Networks
Inte
Daniel,
I get: URL: /net1003/people
Thoughts on what I am doing wrong.
Yeah. Not R'ing TFM. dirname() gives you the name of the
directory ABOVE what you pass.
http://php.net/dirname
Thanks for the pointer. You are indeed correct.
-Jason
--
PHP General Mailing List (http://ww
On Tue, Oct 7, 2008 at 7:57 PM, Jason ML <[EMAIL PROTECTED]> wrote:
>
> But then doing:
>
>$jason = dirname($_SERVER['REQUEST_URI']);
>
>echo "URL: ";
>echo $jason;
>
> I get: URL: /net1003/people
>
> Thoughts on what I am doing wrong.
Yeah. Not R'ing TFM. dirname() g
Hi Micah,
dirname($_SERVER['REQUEST_URI']);
I have tried that and I dont get the proper URI:
Example running print_r($_SERVER); I get: [REQUEST_URI] => /net1003/
people/jason/
But then doing:
$jason = dirname($_SERVER['REQUEST_URI']);
echo "URL:
dirname($_SERVER['REQUEST_URI']);
Thank you,
Micah Gersten
onShore Networks
Internal Developer
http://www.onshore.com
Jason ML wrote:
> Hi PHP'ers,
>
> PHP 4.4.8 and 5.
>
> say I have a url like:
>
> http://www.mydomain.tld/jason/index.php
>
> In that index.php I want to have a piece of code th
Jason ML wrote:
Hi PHP'ers,
PHP 4.4.8 and 5.
say I have a url like:
http://www.mydomain.tld/jason/index.php
In that index.php I want to have a piece of code that runs that tells me
the 'jason' part of the URL so that I can run some custom read only
queries for 'jason'
How can I do this? I
7 matches
Mail list logo