I have this regexp that matches correctly everything I need (all the email addresses NOT inside a link):
/((?<!mailto:|=|[a-zA-Z0-9._%+-])[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,64}(?![a-zA-Z]|<\/[aA]>))/
Unfortunately, since javascript does not support lookbehind, it does not work on my web app. Is there a solution for that?
By definition, you have to look behind to know there is no starting link tag <a>
before the email address.
You can try:
or
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With