Skip to content

Instantly share code, notes, and snippets.

@puginabox
Created December 1, 2014 17:41
Show Gist options
  • Save puginabox/f320b04a2f0924926095 to your computer and use it in GitHub Desktop.
Save puginabox/f320b04a2f0924926095 to your computer and use it in GitHub Desktop.
simple vanilla js popup
<head>
<script>
function poponload() {
testwindow = window.open("",
"mywindow1", "location=1,status=1,scrollbars=1,width=200,height=200");
testwindow.moveTo(50%, 50%);
}
</script>
</head>
<body>
<a href="javascript:void(0)" onclick="javascript: poponload()">
Popped<img src="./sssss_files/x.gif" style="position: absolute; top: -9999px; left: -9999px;">
</a>
</body>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment