javascript - window.open is not applying the given height parameter -


i have onclick event on link inwhich window.open url executed , have given custom width , height it, not accepting , pop window displayed different width , height.. can guide me must wrong that

my window.open syntax follows

onclick='var myw=window.open ("http://www.google.co.jp/","mywindow","location=1,toolbar=1,menubar=1,resizable=1,width=846,height=786"); 

also how change display position of pop window in screen?

note: after replies being positive code.. tried , found after thinking whatever size giving in parameter browser taking more that... may thats due resolution....

your code working fine :

<html> <head> </head> <body> <input type="button" value="cl" onclick='var myw=window.open   ("http://www.google.co.jp/","mywindow","location=1,toolbar=1,menubar=1,resizable=1,width=200,height=200");'> </body> </html> 

for more check this:- http://www.w3schools.com/jsref/met_win_open.asp
window position pop window after opens use:-

window.moveto(50,50);//your window object:- 

the parameters moveto left position followed top position top left corner of window.


Comments

Popular posts from this blog

jasper reports - Fixed header in Excel using JasperReports -

media player - Android: mediaplayer went away with unhandled events -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -