Cum sterg caracterele de rand nou?
Scris: 26-Sep-2007, 14:06:06
Cum pot face ca intr-o portiune din corpul unui mesaj (intre [tex] si [/tex]) toate enter-urile (new line) sa fie sterse?
Am incercat astfel:
#--------[open]-----------------------------------------------------
/includes/bbcode.php
#--------[find]-----------------------------------------------------
// Remove our padding from the string..
#--------[before, add]----------------------------------------------
$text = preg_replace('/\[tex\](.*?)\[\/tex\]/ie', "'[tex]'.str_replace('\r\n','','$1').'[/tex]'", $text);
Nu a avut insa niciun efect!
Am incercat astfel:
#--------[open]-----------------------------------------------------
/includes/bbcode.php
#--------[find]-----------------------------------------------------
// Remove our padding from the string..
#--------[before, add]----------------------------------------------
$text = preg_replace('/\[tex\](.*?)\[\/tex\]/ie', "'[tex]'.str_replace('\r\n','','$1').'[/tex]'", $text);
Nu a avut insa niciun efect!