Jump to content

Archived

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

brown2005

URL Strip Function

Recommended Posts

Hi,

I want to be able to take a URL and strip it so it only comes out with say domain.co.uk.

I want the function to be able to combat the following things....

1) if it has a http:// or https:// at the front or any other alternative
2) if it has www. at front or any other alternative
3) if they just put domain.co.uk it just returns domain.co.uk

Thanks

Share this post


Link to post
Share on other sites
You already started a thread about this, http://www.phpfreaks.com/forums/index.php/topic,107070.0.html .

Share this post


Link to post
Share on other sites
If you checked your old thread there is a reply there will work. Check the last  [url=http://www.phpfreaks.com/forums/index.php/topic,107070.msg429328.html#msg429328]reply[/url] in your old thread. The code provided does what you wnat to do.

[url=http://www.phpfreaks.com/forums/index.php/topic,107070.0.html]Link to old thread[/url]

Do not double post the same problems, even if you didnt make it clear the first time. Edit the first post in the thread, or reply to your thread with a better explanation of what you are trying to do.

Thread closed

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×

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.