What I am trying to do is insert a simple piece of javascript somewhere on the page that will modify the href location of every link on the page to a specific value defined in the script
Such as
Lets say for example the page contains 3 links
<a href=”
<a href=”
<a href=”
I insert a piece of javascript code that changes all the links on the page to the following (without me manually having to change the links within the code)
<a href=”
<a href=”
<a href=”
I am doing this so that once the bit of javascript is entered into the code of the page, all links on that page get replaced with a link pointing to a special offer page(including the original link as a variable)
Can anyone advise how I write the javascript to update all links on the page on the fly every time the page loads??