This code shows how to open a popup window in the center
function popup(url) { var width = 450; var height = 300; var left = (screen.width - width)/2; var top = (screen.height - height)/2; var params = ‘width=’+width+’, height=’+height; params += ‘, top=’+top+’, left=’+left; params += ‘, directories=no’; params += ‘, location=no’; params += ‘, menubar=no’; params += ‘, resizable=no’; params += ‘, scrollbars=no’; params += ‘, status=no’; params += ‘, toolbar=no’; newwin=window.open(url,’Chat’, params); if (window.focus) {newwin.focus()} return false; }
How to use: popup(’http://www.yahoo.com’)
For more details, visit http://sujitkumar.wordpress.com
|
No responses found. Be the first to respond and make money from revenue sharing program.
|