Here is a JavaScript function that open a new window and put in on the center of screen
<script type="text/javascript">
function poponload() {
var left = (screen.width / 2) - (990 / 2);
var top = (screen.height / 2) - (560 / 2);
testwindow = window.open('MyTestPopUp.aspx', 'PopUp', 'location=1,status=1,scrollbars=1,resizable=0,width=990, height=560, top='+top+', left='+left);
}
</script>
<script type="text/javascript">
function poponload() {
var left = (screen.width / 2) - (990 / 2);
var top = (screen.height / 2) - (560 / 2);
testwindow = window.open('MyTestPopUp.aspx', 'PopUp', 'location=1,status=1,scrollbars=1,resizable=0,width=990, height=560, top='+top+', left='+left);
}
</script>
No comments:
Post a Comment