Re: [PHP] RegExp for Forum-List-Code

2002-11-09 Thread Ernest E Vogelsinger
At 17:19 09.11.2002, Jens Lehmann said: [snip] >Hi out there, > >I encountered a lot of problems while trying to convert a list >in Forum-Code (like UBB-Code). > >[list] >[*] item 1 >[*] item 2 >[*] item 3 >[/list] > >should be converted to > > >item 1 >item

Re: [PHP] RegExp for Forum-List-Code

2002-11-09 Thread Jens Lehmann
That's what I thought, too. But it doesn't work. test.php: $text = ' [*] jusfj [*] ijusnf [*] jsf [*] jusdf '; $text = preg_replace('/\[\*\]([^(\[\*\])(<\/ul>)]*)/i','$1',$text); $text = htmlentities($text); Output: jusfj ijusnf jsf jusdf I tested some different things, which didn't work

Re: [PHP] RegExp for Forum-List-Code

2002-11-09 Thread Marek Kilimajer
untested: preq_replace('/\[\*\]([^(\[\*\])(<\/ul>)]*)/i','$1',$text); Jens Lehmann wrote: Hi out there, I encountered a lot of problems while trying to convert a list in Forum-Code (like UBB-Code). [list] [*] item 1 [*] item 2 [*] item 3 [/list] should be converted to item 1 item 2 item

[PHP] RegExp for Forum-List-Code

2002-11-09 Thread Jens Lehmann
Hi out there, I encountered a lot of problems while trying to convert a list in Forum-Code (like UBB-Code). [list] [*] item 1 [*] item 2 [*] item 3 [/list] should be converted to item 1 item 2 item 3 I converted the first one to [*] item 1 [*] item 2 [*] item 3 Now I need a Regexp for co