i have the string which is a part of an xml.
a<b>b</b>c<i>d</i>e<b>f</b>g
the problem is that i want to extract from the string the parts that are not inside any tags.
so i need to extract the string”aceg” from this string and leave the characters “bdf”
how can this be done?
Edit:
this was a part of an xml
let asume its
<div>a<b>b</b>c<i>d</i>e<b>f</b>g</div>
now its a valid xml 🙂
That string is not valid XML.
However, assuming you had a valid XML string, then you could do something like this:
This will print out the string “bdf”