Re: Problem with RegEx for BBCode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Nov 27, 2010 at 14:05, Daniel P. Brown
<daniel.brown@xxxxxxxxxxxx> wrote:
> On Sat, Nov 27, 2010 at 13:55, Asmann, Roland <Roland.Asmann@xxxxxxxxx> wrote:
>>
>> $s = preg_replace("/\[i\]((\s|.)+?)\[\/i\]/", "<i>\\1</i>", $s);
>
>    This is exactly what I meant when I erroneously said, "library."

    Without seeing the rest of your code, try adjusting this
particular preg_replace() line as follows:

        $s = preg_replace("/\[i\](.*)\[\/i\]/Us","<i>$1</i>",$s);



-- 
</Daniel P. Brown>
Dedicated Servers, Cloud and Cloud Hybrid Solutions, VPS, Hosting
(866-) 725-4321
http://www.parasane.net/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux