i need your help with an regex in Javascript, again.
Sometimes i have empty p-Tags in the DOM and i will remove them all.
Some look like:
<p></p>
others like:
<p> </p>
I think for an regex pro is this very lame, but i’m not good with it 🙁
so thanks in advance 🙂
You don’t need to use regex for something this simple. Most likely you need to iterate over all the ‘p’ elements anyway. Something like this works:
http://jsfiddle.net/mqchen/3pV2P/