Skip to content

Instantly share code, notes, and snippets.

@bytespider
Created May 19, 2010 22:00
Show Gist options
  • Save bytespider/406895 to your computer and use it in GitHub Desktop.
Save bytespider/406895 to your computer and use it in GitHub Desktop.
function openURL(url) {
var a = d.createElement('a'), d = document;
a.href = url;
a.dispatchEvent(d.createEvent('MouseEvents').initMouseEvent('click'));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment