RE: [PHP] Regex question
| From: | Jon Haworth | Date: | Wed, 09 Jan 2002 16:14:06 +0000 |
| Subject: | RE: [PHP] Regex question | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-79924@lists.php.net to get a copy of this message | ||
> As far as I can see (notice: I'm not a regex-king ;) the regex seems
correct
> to me. The only thing I'm wondering about is the "/^<" (second last line
of
> the citation). Together with your expression in the array it results in
> preg_match("/<\/<!\[CDATA\[/", ...)
> I'm wondering if that (</<![CDATA...) is really what you want to match
(and
> not only <![CDATA without the trailing </).
Aaarrrrrrrrrrgh <thump> <thump> <thump> <thump> <thump>
That's it! Thanks very much Stefan.
It's trying to match a closing HTML tag, but of course that doesn't apply to
CDATA, so it all went pear-shaped. I stared at that bloody regex for hours,
as well <sigh>
Cheers
Jon