i/p: <a><REF><a><REF><a></REF></REF><a>
Expected o/p: <b><REF><a><REF><a></REF></REF><b>
From the above string replace which is outside of ... tag with
Tried with below regex but its working only for one level but not for nested:
(<a>)(?!(.(?!<REF>))*?(<\/REF>))
Given regex is working for <a><REF><a><?REF><a>
but its failing with <a><REF><a><REF><a></REF></REF><a>
.
Actual String: <a><REF><a><REF><a><BR><REF><BR></REF><a></REF></REF><a>
Expected String: <b><REF><a><REF><a><BR><REF><BR></REF><a></REF></REF><b>
` and also: `Equals Desired Result? true` – Oct 17 '19 at 12:03