Quote Originally Posted by visualAd
Your regular expression is not meant to have hashes in "#"
I use hashes. Lots of characters can be used as start and end tokens.


The expression doesn't work because you've unnecessarily escaped the double quote characters. These do not need to be escaped in single-quoted string literals.

However, I would use the DOM (as advised) and an XPath query.