peddhapati
asked on
Please wait... JavaScript
Hi
I would like to have a JavaScript that would open a intermediate window saying "Please Wait..." while loading the new window.
Note:
1. The solution has to work in both IE and Netscape
2. The requested window should remain in the background while you were able to see the small pop up window with this message.
3. Once the new window is loaded completly it should replace the old window and the poped up window should disappear.
Also, I would like to have the code in the source page or in a differnt file which is called from the source page. Since I have no control over the links from the source page.
Thanks
I would like to have a JavaScript that would open a intermediate window saying "Please Wait..." while loading the new window.
Note:
1. The solution has to work in both IE and Netscape
2. The requested window should remain in the background while you were able to see the small pop up window with this message.
3. Once the new window is loaded completly it should replace the old window and the poped up window should disappear.
Also, I would like to have the code in the source page or in a differnt file which is called from the source page. Since I have no control over the links from the source page.
Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
almost what you want here http://www.dhtmlcentral.com/script/script.asp?id=17 only it doesn't display in a popup window, instead hides the content of the page until it is ready to display
nzjonboy
nzjonboy
try this,
<div id=loadingmsg style="position:absolute; z-index:2; left:300; top:150; width:200; height:100; border-width:4; border-style:ridge; background-color:#eeeeee"> <center><b r><br><fon t face='Arial' Size=3><b>Please Wait.....</b></font><br><b r></center ></div>
<html>
<head>
<script>
function hidemsg(){
if (document.all)
document.all.loadingmsg.st yle.visibi lity='hidd en';
if (document.layers)
document.loadingmsg.visibi lity='hidd en';
if (document.getElementById)
document.getElementById('l oadingmsg' ).style.vi sibility=' hidden';
}
</script>
</head>
<body onload="setTimeout('hidems g()',1000) ;">
<P> welcome to this page </P>
</body>
</html>
the message will disappear one second after loading the page.
<div id=loadingmsg style="position:absolute; z-index:2; left:300; top:150; width:200; height:100; border-width:4; border-style:ridge; background-color:#eeeeee">
<html>
<head>
<script>
function hidemsg(){
if (document.all)
document.all.loadingmsg.st
if (document.layers)
document.loadingmsg.visibi
if (document.getElementById)
document.getElementById('l
}
</script>
</head>
<body onload="setTimeout('hidems
<P> welcome to this page </P>
</body>
</html>
the message will disappear one second after loading the page.
MSIE only
=========
load.html
=========
<script language="javascript">
wSplash = window.open("splash.html", "splash"," height=100 px,width=2 00px,cente r=1");
if (wSplash.opener == null) wSplash.opener = window;
//MSIE only
document.onreadystatechang e = checkit;
function checkit() {
if (document.readyState == "complete") { wSplash.close(); wSplash = null; }
}
</script>
<html>
<head>
<title>Waiting</title>
</head>
<body style="margin:0px;" scroll="no">
<iframe src="http://www.cisco.com" height="100%" width="100%" frameborder="0" marginheight="0" marginwidth="0"></iframe>
</body>
</html>
splash.html
===========
<html>
<head>
<title>Splash Window</title>
</head>
<body style="text-align:center;f ont-family :Tahoma;fo nt-size:10 pt;">
<div>Loading...</div>
</body>
</html>
=========
load.html
=========
<script language="javascript">
wSplash = window.open("splash.html",
if (wSplash.opener == null) wSplash.opener = window;
//MSIE only
document.onreadystatechang
function checkit() {
if (document.readyState == "complete") { wSplash.close(); wSplash = null; }
}
</script>
<html>
<head>
<title>Waiting</title>
</head>
<body style="margin:0px;" scroll="no">
<iframe src="http://www.cisco.com" height="100%" width="100%" frameborder="0" marginheight="0" marginwidth="0"></iframe>
</body>
</html>
splash.html
===========
<html>
<head>
<title>Splash Window</title>
</head>
<body style="text-align:center;f
<div>Loading...</div>
</body>
</html>
This question has been abandoned. I will make a recommendation to the moderators on its resolution in a week or so. I appreciate any comments that would help me to make a recommendation.
In the absence of responses, I may recommend DELETE unless it is clear to me that it has value as a PAQ. Silence = you don't care
ahosang
In the absence of responses, I may recommend DELETE unless it is clear to me that it has value as a PAQ. Silence = you don't care
ahosang
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
PAQ - NO REFUND
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
ahosang
EE Cleanup Volunteer
I will leave a recommendation in the Cleanup topic area that this question is:
PAQ - NO REFUND
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
ahosang
EE Cleanup Volunteer
I recommend a split among adowns, third, and b1xml2. They put effort into the question and contributed meaningful content.
Fritz the Blank
Fritz the Blank
Points split:
SpideyMod
Community Support Moderator @Experts Exchange
third, points for you at
https://www.experts-exchange.com/questions/20580413/points-for-third-re-various.html
b1xml2, points for you at
https://www.experts-exchange.com/questions/20580412/points-for-b1xml2-re-various.html
SpideyMod
Community Support Moderator @Experts Exchange
third, points for you at
https://www.experts-exchange.com/questions/20580413/points-for-third-re-various.html
b1xml2, points for you at
https://www.experts-exchange.com/questions/20580412/points-for-b1xml2-re-various.html
http://developer.irt.org/script/timeout.htm
Fritz the Blank