I have some markup which contains the firebug hidden div.
(long story short, the YUI RTE posts content back that includes the hidden firebug div is that is active)
So, in my posted content I have the extra div which I will remove server side in PHP:
<div firebugversion="1.5.4" style="display: none;" id="_firebugConsole"></div>
I cant seem to get a handle on the regex I would need to write to match this string, bearing in mind that it won’t always be that exact string (version may change).
All help welcome!
Regex is not the best tool for the job, but you can try:
The
[…]is a character class. Something like[aeiou]matches one of any of the lowercase vowels.[^…]is a negated character class.[^aeiou]matches one of anything but the lowercase vowels.The
*is the zero-or-more repetition. Thus,[^>]*matches a sequence of anything but>.If you want to target the
idspecifically, you can try:The
\bis the word boundary anchor.