Hi all.
I have used showmodaldialog for a popup window. it works fine in IE but shows :Error: showModalDialog is not defined.
I have gone through many forums but haven't got satisfactory solution.
Moreover i dont want the popupwindow to be closed manually .It gets closed automatically as the time fixed for its display gets over.
This functionality is working fine in IE but if someone could help me out to run it in Mozilla and other browsers,it would be great.
Below is my code:
[HTML]function getUpload(sForm){
{
var synclose=null;
while(synclose==null)
{
var sURL = sForm;
var rst = showModalDialog(sURL, '', 'dialogWidth:600px; toolbar:0; dialogHeight:300px; status:0; resizable=0;');
};
}
}
</script>
</head><?php
$mode=1;
if($mode==1)
{
?>
<body onLoad="getUpload('syncpop.php')"> </body>
<?php
}
?></html>
[/HTML]
//Here is the syncpop.php page
[HTML]
<html>
<head>
<META HTTP-EQUIV=REFRESH CONTENT=2>
<body>
<? $mode=1;
if ($mode==1){?>
<script language="javascript">
document.write("Synchonizing, please wait...");
</script>
<? }
if($mode==0){?>
<script type="text/javascript">
alert('Last Synchronizaton completed successfully');
window.returnValue = "Success!!";
window.close();
</script>
<? }?></body>
</html>[/HTML]
The code involves a little bit of php but it hardly makes difference..i want the javascript function only that could solve my above mentioned purpose.
Thanks and Regards
TechnoAtif