For example, I have a string like this:
Line 1
<br/>
<br/>
Line 2
<br/>
<br/>
<br/>
Line 3
I need to detect and replace the duplicated and attached string like the <br/>'s so it will be only 1 <br/> instead. So the final result I expect is:
Line 1
<br/>
Line 2
<br/>
Line 3
Anyone can help me with the regex? explanation will be appreciated.