Hello, I am in a situation where I am having HTML markup with some text outside of it (leading or trailing). What regex should I be using? For example:
some text over here
<Html>
<Title>website</Title>
<Body>
text text text
<Div>xxxxx</Div>
</Body>
</Html>
ending text
So, I should be getting "some text over here" and "ending text" only....All the html + text inside every tag should not deducted.
Another example:
abcdef<div>xyz</div>
It should return "abcdef"
Any approach or suggestion would be greatly appreciated. Thank you