note 104315 added to function.preg-replace

From: Date: Wed, 08 Jun 2011 12:44:00 +0000
Subject: note 104315 added to function.preg-replace
Groups: php.notes 
Request: Send a blank email to php-notes+get-180330@lists.php.net to get a copy of this message
A simple pattern to remove the protocol from a given URL: preg_replace("/\A(http:\/\/)|(ftp:\/\/)/i", "", trim($_POST['url'])); ---- Server IP: 69.147.83.197 Probable Submitter: 46.227.3.210 ---- Manual Page -- http://www.php.net/manual/en/function.preg-replace.php Edit -- https://master.php.net/note/edit/104315 Del: integrated -- https://master.php.net/note/delete/104315/integrated Del: useless -- https://master.php.net/note/delete/104315/useless Del: bad code -- https://master.php.net/note/delete/104315/bad+code Del: spam -- https://master.php.net/note/delete/104315/spam Del: non-english -- https://master.php.net/note/delete/104315/non-english Del: in docs -- https://master.php.net/note/delete/104315/in+docs Del: other reasons-- https://master.php.net/note/delete/104315 Reject -- https://master.php.net/note/reject/104315 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#180330) next »