0

Here is my sentence :

<p>
    random <b>html content</b> 
    <a 
        href="http://www.google.com" 
        target="_blank" 
        data-saferedirecturl="https://www.google.com/url?hl=fr&amp;q=http://www.randomsite.com&amp;source=gmail&amp;ust=1481293002613000&amp;usg=AFQjCNHR0HJfUDpRN_7vq022fQiLzXf0yQ"
    >
        <span class="il">content</span>.n1
    </a> 
    fdfdf<br/>
    dsdsd <a href="dsdsdsds">content n2</a>

I'm trying to get all the content inside the link :

<span class="il">content</span>.n1

and

content n2

I tried :

/<a.*\>{1}(.*)<\/a>/

But It seems I cannot "target" the first closing tag ">" which can allow me to target the links content

https://regex101.com/r/coekvw/2

Thanks for any help.

Chuck Norris
  • 1,125
  • 1
  • 12
  • 28

0 Answers0