note 110677 deleted from function.preg-replace by langemeijer

From: Date: Sun, 25 Nov 2012 06:19:53 +0000
Subject: note 110677 deleted from function.preg-replace by langemeijer
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-192138@lists.php.net to get a copy of this message
Note Submitter: 360 at xonline dot com ---- i have made this code for my php but i cant figure out how to remove only span tags.. the function is to copy what ever in the <b class="(.*)">(.*)</b> but, i want to remove the span class or span style. the grabbed <b class="sleepy"><span class="good" style="color: white; font-weight: bold; text-shadow: 0px 0px 0.4em #FF9966, 0px 0px 0.4em #FF9966, 0px 0px 0.4em #FF9966, 0px 0px 0.4em #FF9966, 0px 0px 0.4em #FF9966;" title="CODER">blood</span></b> my php preg_match('%<b class="(.*)">(.*)</b>%U', $mess, $mem); $name = $mem[2]; how do i copy "blood" without span class, because some "blood" dont have span class and span style and some have

« previous php.notes (#192138) next »