i have a page that displays a table with info from a database.
each entry has a link for a popup-window displaying a photo.
the pop-up itself works fine. however, as soon as the pop-up
is displayed the parent window automatically scrolls to the
top, i.e. you have to scroll down again to where you were. this
window, btw, is part of a frameset. how do i get it to keep it's
position?! what am i missing?
thanks in advance,
miller
------------------------------------
the function in the header:
<SCRIPT Language="JavaScript">
<!--
function popup(link)
{
popupWin = window.open('', 'ShowMenu', 'width=420,height=350,toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,left = 130,top = 100');
// focus window (only for > Navigator 3.0)
if ((navigator.appName != "Microsoft Internet Explorer") && (navigator.appVersion.substring(0,1) == "3"))
popupWin.focus();
popupWin.document.write('<TITLE>'+ link +'</TITLE>\n');
popupWin.document.write('<BODY Bgcolor="#000000">\n');
popupWin.document.write('<CENTER>\n');
popupWin.document.write('<IMG Src=http://www.webdeveloper.com/forum/archive/index.php/"../images/food/' + link + '">\n');
popupWin.document.write('<br><a href=http://www.webdeveloper.com/forum/archive/index.php/"javascript:window.close();"><font color="#993333" face="Verdana, Arial, Helvetica, sans-serif" size="-1">close window</a>\n');
popupWin.document.write('</font></CENTER>\n');
popupWin.document.write('</BODY>\n');
}
-->
</script>
------------------------------------
this is in the body:
<A Href=http://www.webdeveloper.com/forum/archive/index.php/"#" onClick="popup('<%=rs("foto_r")%>');" onMouseover="msg('Show Picture'); return true;" onMouseout="msg('');">
<img src=http://www.webdeveloper.com/forum/archive/index.php/"../images/fotoex.jpg" border="0"></a>
non-important note: rs("foto_r") is a variable with the name of the photo i wish to display in the pop-up.
each entry has a link for a popup-window displaying a photo.
the pop-up itself works fine. however, as soon as the pop-up
is displayed the parent window automatically scrolls to the
top, i.e. you have to scroll down again to where you were. this
window, btw, is part of a frameset. how do i get it to keep it's
position?! what am i missing?
thanks in advance,
miller
------------------------------------
the function in the header:
<SCRIPT Language="JavaScript">
<!--
function popup(link)
{
popupWin = window.open('', 'ShowMenu', 'width=420,height=350,toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,left = 130,top = 100');
// focus window (only for > Navigator 3.0)
if ((navigator.appName != "Microsoft Internet Explorer") && (navigator.appVersion.substring(0,1) == "3"))
popupWin.focus();
popupWin.document.write('<TITLE>'+ link +'</TITLE>\n');
popupWin.document.write('<BODY Bgcolor="#000000">\n');
popupWin.document.write('<CENTER>\n');
popupWin.document.write('<IMG Src=http://www.webdeveloper.com/forum/archive/index.php/"../images/food/' + link + '">\n');
popupWin.document.write('<br><a href=http://www.webdeveloper.com/forum/archive/index.php/"javascript:window.close();"><font color="#993333" face="Verdana, Arial, Helvetica, sans-serif" size="-1">close window</a>\n');
popupWin.document.write('</font></CENTER>\n');
popupWin.document.write('</BODY>\n');
}
-->
</script>
------------------------------------
this is in the body:
<A Href=http://www.webdeveloper.com/forum/archive/index.php/"#" onClick="popup('<%=rs("foto_r")%>');" onMouseover="msg('Show Picture'); return true;" onMouseout="msg('');">
<img src=http://www.webdeveloper.com/forum/archive/index.php/"../images/fotoex.jpg" border="0"></a>
non-important note: rs("foto_r") is a variable with the name of the photo i wish to display in the pop-up.