I have a dynamically generated string like :
String s = <span><input style='font-weight:bold'>Hello team</input></span>
I want to split the string as:
String startTag = <span><input style='font-weight:bold'>
String endTag = </input></span>
String content = Hello Team
The String s can be anything (depending on the code) like
<span style='font-weight:bold'>Hello team</span>
or
<td><input style='font-weight:bold'>Hello team</input></td>
So, I want to split based on the index of '>' and '<'?
How can I achieve that?