/ Published in: JavaScript

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
// construct for explorer compatibility var newwindow = ''; // EG: pop_up_window("http://www.google.com", 200, 200) function pop_up_window(url, sizeh, sizew) { if (!newwindow.closed && newwindow.location) { newwindow.location.href = url; } else { newwindow=window.open(url,'name','height=' + sizeh + ', width=' + sizew + ', status=1, resizable=1, location=1, scrollbars=1 '); /*resizable=1*/ if (!newwindow.opener) newwindow.opener = self; newwindow.moveTo(100,100); } if (window.focus) {newwindow.focus()} return false; }
Comments
