Home Apache PHP Ubuntu MySQL Linux HTML Win CSS Perl Javascript Rants Retro
 
Print This Page
Date Posted: Wednesday 21st of December 2011 | Category: PHP
remove http:// from url string
To strip the http:// from a webaddress using php, copy and paste the following code.


<?php echo str_replace(array('http://','https://'), '','http://www.techheadz.co.uk'); ?>


The code was modified to fit my own needs.
A proper function can be found by visiting refactormycode


Related Links:
- Refactor My Code