$_ = join '', <DATA>; s/(<a href="https?:\/\/(?:(?!target=).)*?)>/$1 target="_blank">/igs; print; __DATA__ <a href="dsfsdf">sdfdsf</a> <a href="http://dsfsdf">sdfdsf</a> <a href="https://dsfsdf">sdfdsf</a> <a href="http://dsfsdf" target="_blank">sdfdsf</a> <a href="http://dsfsdf" >sdfdsf</a>
In reply to Re: Regexp: Match anything except a certain word
by TedPride
in thread Regexp: Match anything except a certain word
by fraktalisman
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |