forked from science-ation/science-ation
- Don't open the info window until it is requested.
This commit is contained in:
parent
87f1452919
commit
f17f07ff94
@ -88,6 +88,7 @@
|
|||||||
);
|
);
|
||||||
?>
|
?>
|
||||||
<script language="javascript" type="text/javascript">
|
<script language="javascript" type="text/javascript">
|
||||||
|
var infowindow = '';
|
||||||
function addbuttonclicked(id)
|
function addbuttonclicked(id)
|
||||||
{
|
{
|
||||||
document.forms.tours.action.value="add";
|
document.forms.tours.action.value="add";
|
||||||
@ -102,10 +103,11 @@ function openinfo(id)
|
|||||||
else
|
else
|
||||||
currentid=document.forms.tours["studentlist[]"].options[document.forms.tours["studentlist[]"].selectedIndex].value;
|
currentid=document.forms.tours["studentlist[]"].options[document.forms.tours["studentlist[]"].selectedIndex].value;
|
||||||
|
|
||||||
window.open("tours_assignments.php?action=info&id="+currentid,"Student Tour Rank Information","location=no,menubar=no,directories=no,toolbar=no,width=770,height=300,scrollbars=yes");
|
infowindow = window.open("tours_assignments.php?action=info&id="+currentid,"Student Tour Rank Information","location=no,menubar=no,directories=no,toolbar=no,width=770,height=300,scrollbars=yes");
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function switchinfo()
|
function switchinfo()
|
||||||
{
|
{
|
||||||
if(document.forms.tours["studentlist[]"].selectedIndex != -1)
|
if(document.forms.tours["studentlist[]"].selectedIndex != -1)
|
||||||
@ -115,7 +117,10 @@ function switchinfo()
|
|||||||
|
|
||||||
document.forms.tours.studentinfobutton.disabled=false;
|
document.forms.tours.studentinfobutton.disabled=false;
|
||||||
document.forms.tours.studentinfobutton.value=currentname;
|
document.forms.tours.studentinfobutton.value=currentname;
|
||||||
openinfo();
|
|
||||||
|
if(!infowindow.closed && infowindow.location) {
|
||||||
|
openinfo();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user