Possible Duplicate:
Add http:// prefix to URL when missing
I'm using this code like this:
<?php echo $_GET['i']; ?>
myweb.com/sample.php?i=http://sample.com
But I want to make sure it always has http://
just in case this is provide myweb.com/sample.php?i=sample.com
How can I make this code <?php echo $_GET['i']; ?>
make sure always adds the http://
in case is missing?