Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
174
rated 0 times [  179] [ 5]  / answers: 1 / hits: 15715  / 14 Years ago, thu, july 1, 2010, 12:00:00

What I want to do is to change the size of a window and create a window next to it so they are exactly next to each other. In that sense, I need to position to the new window to the top right part of the screen, the way I am doing it is not working (code is below), I need help :)



function () { 
var viewportwidth = document.documentElement.clientWidth;
var viewportheight = document.documentElement.clientHeight;
window.resizeBy(-300,0);
window.open(something.htm,
mywindow,
width=300,
height=viewportheight,
left=(viewportwidth - 300),
top=0,
screenX=0,
screenY=0);
}

More From » browser

 Answers
32
var viewportwidth = document.documentElement.clientWidth;
var viewportheight = document.documentElement.clientHeight;
window.resizeBy(-300,0);
window.moveTo(0,0);

window.open(http://google.com,
mywindow,
width=300,left=+(viewportwidth-300)+,top=0);

[#96359] Tuesday, June 29, 2010, 14 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
elvisissacg

Total Points: 410
Total Questions: 108
Total Answers: 121

Location: Monaco
Member since Tue, Jun 16, 2020
4 Years ago
;