Is it possible to split a string by space "" and to ignore the html tags in it ?
The html tags may have style elements like : style="font-size:14px; color: rgb(0, 0, 0)" .....
The string i'm talking about is:
<div class="line"><span style="color: rgb(0,0,0)">John</span><u> has</u><b> apples</b></div>
If you can see i have space character inside the u
tag and inside the b
tag
What i am trying to get is the text to split as following
<div class="line"><span style="color: rgb(0,0,0)">John</span><u>
has</u><b>
apples</b></div>
I have the following regex but it does not give me the rest of the string, just the first 2 parts :
[\<].+?[\>]\s