I want to find out if a string contains [url]http://[/url] at the front of it. How would I do this?
Thanks Adam
$pattern="/http:\/\/[À×]*$/";
if (preg_match($pattern,$string,$matches)) { the codes you want to execute....... }
hi. here is a good article for this and many more related problems.
Regular expressions? Overkill.
if(substr($string,0,7)=='http://')
even better just snip the [url]http://[/url] out and treat them all the same.