I am working on an automation for building Landingpages.
A copy/pastes from a word doc to a TinyMCE textarea which creates the in the output.
so if I copy/paste something like this:
This is my Website.
from a word doc - the output of it after sending the form will look like this:
This is my <a href="http://www.google.com">Website</a>.
I want to append to every link within an <a href>
tag (only within an <a href>
tag!) something like this:
?utm=foo_foo_foo
so it will look like this:
This is my <a href="http://www.google.com?utm=foo_foo_foo">Website</a>.
P.S: urls can end with "/" or without, this shouldn't matter, but should work both ways.
P.S2: TinyMCR adds the tags by itself (if you haven't noticed me mentioning it..,). I just need to append to a string that looks like this:
$string = "This is my <a href="http://www.google.com">Website</a>.";