Thread: PHP Help
View Single Post
Old 07-15-2012, 06:21 PM  
kazymjir
Confirmed User
 
kazymjir's Avatar
 
Industry Role:
Join Date: Oct 2011
Location: Munich
Posts: 411
Code:
<?php
 
$str = "Remove this [tags]amateur, anal, teen,etc[/tags] stuff out of here!";
 
$regexp = "#\[tags\](.*?)\[/tags\]#is";
 
echo preg_replace($regexp, "", $str);
 
?>
__________________
http://kazymjir.com/
kazymjir is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote