Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

bigandy

macrumors G3
Original poster
Apr 30, 2004
8,852
7
Murka
I'm writing a form that has a weblink in it, and i need to check that it has a "http://" at the start, and if not add it, when the form is submitted.

how would i go about doing this? i've hunted around the fishnet, but not come accross the soultion! :(
 
After the form has been submitted..

PHP:
if (substr($_POST['urlform'], 0, 7)!='http://') $_POST['urlform'] = 'http://'.$_POST['urlform'];
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.