Below is the javascript method that opens a popup with specific height,width,location etc
function openQuadPopup(val) {
var width = screen.width - 100;
var height = screen.height - 100;
var leftPos = (screen.width - width - 30) / 2;
var topPos = (screen.height - height - 30) / 2;
myWindow = window.open('TestPage.aspx?QueryStringValue=' + val, 'NameForPopup', 'menubar=0,resizable=0,width=' + width + ',height=' + height + "'");
myWindow.moveTo(leftPos, topPos);
}
function openQuadPopup(val) {
var width = screen.width - 100;
var height = screen.height - 100;
var leftPos = (screen.width - width - 30) / 2;
var topPos = (screen.height - height - 30) / 2;
myWindow = window.open('TestPage.aspx?QueryStringValue=' + val, 'NameForPopup', 'menubar=0,resizable=0,width=' + width + ',height=' + height + "'");
myWindow.moveTo(leftPos, topPos);
}
No comments:
Post a Comment