Hi there,
I'm having window-sizing problems an would REALLY appreciate some help.
I want on selection of button A to open new window A (which contains windows media player) in one size window.
And selection of button B to open up new window B (which contains a flash movie) in a different size window.
And I CAN do this...if both windows are opened WITHOUT th other eing present.
HOWEVER, if the reader opens B when A is open, then I find that the new window (B) opens in A's window...so I get the wrong size window for the content.
HOW CAN I GET the trigger that opens window B (button B) to CLOSE window A if it happens to be open already?
The code I am using is below...thanks so much for helping.
In the HEAD
<script language="JAVASCRIPT" type="TEXT/JAVASCRIPT">
<!-- Hide script from old browsers
function newWindow(vows) {
vowsWindow = window.open(vows, "demoWin",
"top=0,left=0,width=450,height=301,scrollbars=no")
vowsWindow.focus()
}
function newWindow1(demo) {
demoWindow = window.open(demo, "demoWin",
"top=10,left=5,width=320,height=120,scrollbars=no")
demoWindow.focus()
}
// End hiding script from old browsers -->
And in the BODY
A is here <a href="javascript:newWindow('A.htm')"> etc....
For B click here <a href="javascript:newWindow1('B.htm')"> etc....
I'm having window-sizing problems an would REALLY appreciate some help.
I want on selection of button A to open new window A (which contains windows media player) in one size window.
And selection of button B to open up new window B (which contains a flash movie) in a different size window.
And I CAN do this...if both windows are opened WITHOUT th other eing present.
HOWEVER, if the reader opens B when A is open, then I find that the new window (B) opens in A's window...so I get the wrong size window for the content.
HOW CAN I GET the trigger that opens window B (button B) to CLOSE window A if it happens to be open already?
The code I am using is below...thanks so much for helping.
In the HEAD
<script language="JAVASCRIPT" type="TEXT/JAVASCRIPT">
<!-- Hide script from old browsers
function newWindow(vows) {
vowsWindow = window.open(vows, "demoWin",
"top=0,left=0,width=450,height=301,scrollbars=no")
vowsWindow.focus()
}
function newWindow1(demo) {
demoWindow = window.open(demo, "demoWin",
"top=10,left=5,width=320,height=120,scrollbars=no")
demoWindow.focus()
}
// End hiding script from old browsers -->
And in the BODY
A is here <a href="javascript:newWindow('A.htm')"> etc....
For B click here <a href="javascript:newWindow1('B.htm')"> etc....