On 04 May 2006 14:04, tJey wrote:

> Hi. I have problem with preg_replace_callback. It seems that my
> pattern is bad, but I can't find any error.
> 
> Pattern : 
> this pattern is intended to find strings like "[field]", "[
> fi12_eld]"... 
> 
> but every time I get warning message
> "Warning: preg_replace_callback(): Delimiter must not be alphanumeric
> or backslash in test.php on line 100"

The error message suggests you haven't included the necessary pattern 
delimiters, like for example:

   preg_replace_callback("|\[\s*((\d|\w|_)+)\s*\]|", ...
or
   preg_replace_callback("@\[\s*((\d|\w|_)+)\s*\]@", ...
or
   preg_replace_callback("{\[\s*((\d|\w|_)+)\s*\]}", ...

etc, etc!

Cheers!

Mike

---------------------------------------------------------------------
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Headingley Campus, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730      Fax:  +44 113 283 3211 


To view the terms under which this email is distributed, please go to 
http://disclaimer.leedsmet.ac.uk/email.htm

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

Reply via email to