Skip to content

Instantly share code, notes, and snippets.

@jhrr
Created February 16, 2014 16:02
Show Gist options
  • Save jhrr/9036447 to your computer and use it in GitHub Desktop.
Save jhrr/9036447 to your computer and use it in GitHub Desktop.
function doPopups() {
if (document.getElementsByTagName) {
var links = document.getElementsByTagName("a");
for (var i=0; i < links.length; i++) {
if (links[i].className.match("help")) {
links[i].onclick = function() {
window.open(this.getAttribute("href"));
return false;
};
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment