Jump to content

Regular Expression help needed


music_lp90

Recommended Posts

Thanks Jesh, I think it is finding the trigger, but I'm getting an error: Warning: preg_replace() [function.preg-replace]: Unknown modifier 'o' in C:\wamp\www\mambots\content\mosInclude.php on line 22This is line 22: $row->text = preg_replace( $find, $replace, $row->text );I'm not sure what Unkown modifier 'o' means.

Link to comment
Share on other sites

And I think a * would be better than +?
If there is a chance of there being two sets of {mosInclude}{/mosInclude}s in the string to match, then the lazy lookup (?) would be more appropriate. You're probably right, however, that .*? (lazy zero-or-more) would be better than .+? (lazy one-or-more).
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...