Jump to content

Archived

This topic is now archived and is closed to further replies.

BostonMark

help with $_SERVER['SERVER_NAME']

Recommended Posts

Hi,

I'm using $baseurl = $_SERVER['SERVER_NAME'] to get the URL on my site. Now I want to have a way to say if anywhere in $baseurl it says "yaddayaddayadda" then ..., else ....

substr is not good because I need to know where to begin for the string to be at. I just want to say is "yaddayaddayadda" anywhere in the String $baseurl

Thanks

Share this post


Link to post
Share on other sites
Take a look at the [a href=\"http://www.php.net/strpos\" target=\"_blank\"]strpos()[/a] function.

Ken

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.