Howdy cats,
I’m pretty new to this, and my only learnin’ in coding comes from watching and reading Chris’s posts. I’m trying to get links that are external to the site I’m writing to pop up in a new window/tab. Obviously, this is do-able, as many sites do this but I’m unsure how to achieve it.
I know how to get anchor links with ‘rel=”external”‘ to open in a new window, but can someone please elucidate me as to how to add that tag to links that are external to my site via Javascript? All of the techniques I’ve come across so far can do this for links that begin with “http://”, however all of my internal links start with this too so I’m a bit lost.
Thanks in advance, and sorry for my ignorance! I’m sure this is a common issue, but I haven’t been able to find the solution yet.
Michael