Reputation: 81
I want to remove an HTML tag but only with specific content is appear, like this:
<strong>\u00a0</strong>
I want to remove the tag only if \u00a0 is appearing inside the tag. Any solution?
Upvotes: 0
Views: 29
Reputation: 2745
If what you mean is to match the exact string \u00a0
, then the regex is just about escaping a couple of slashes:
s/<strong>\\u00a0<\/strong>//g
Or, more readable:
s|<strong>\\u00a0</strong>||g
If you mean to match the actual unicode character U+00A0
, then the regex is:
s/<strong>\u00a0<\/strong>//g
s/<strong>\x{00a0}<\/strong>//g
Upvotes: 1