On Thursday 11 March 2004 22:50, Dave Carrera wrote: > I want to end up with a part of a string returned by $_POST to work with in > my function. > > The string might be put into the text box like so, it’s a domain name > checker, > > http://www.domainname.com > > I have already got rid of the http:// and www bits but I need to know how > to get rid of the .com bit before proceeding with my check. So I will only > be left with "domainname" for my function. > > I have looked at eregi, split, spliti but to no joy so any help would be > gratefully received.
Why don't you just explode() on '.' and then pick the bits you need? -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * ------------------------------------------ Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general ------------------------------------------ /* The power to destroy a planet is insignificant when compared to the power of the Force. - Darth Vader */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php