/***************************************************** File : NewWindow.js.txt Project : kajames.com Author : Kevin James Copyright (c) 2005, 2006 Kevin James, kajames.com *****************************************************/ // Function to create new window icons beside links with the rel="external" attribute function UpdateExternalLinks() { // Get all the links var arrLinks = document.getElementsByTagName("a"); for (var i=0;i"; // Now insert the clone in front of the original link arrLinks[i].parentNode.insertBefore(newWin, arrLinks[i]); } catch (e) { // We won't do anything here, just ignore the error and continue } } } } // Make sure we run it when the page has loaded window.onload = UpdateExternalLinks;