473,289 Members | 1,917 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,289 software developers and data experts.

Help with status bar - still showing load in progress even after page load

Hi,

I'm having an issue with the status bar in Mozilla and Netscape showing that
it is still waiting on the page to load even after it is finished. This
problem does NOT occur with IE.

In summary, I am using a onLoad event in the BODY tag to communicate back to
another server each time a page finishes loading. I do this by using a "new
Image()" and setting the .src property to the server. The .src includes a
value in the querystring so I know what request it was that finished
loading.

The challenge here is that the status bar still shows "Transferring data
from www.mysite.com..." despite the image being loaded. It never clears and
leaves the user with the impression that there was a problem loading the
page. My web server logs at the mysite.com show that the browser does
indeed make a request for the image and I get the querystring just fine and
it returns a status of 200 so the image is being found and served ok.

I've tried everything I can think of to solve this and really could use your
help please. Bottom line is that if you use the "new Image" statment from
within the OnLoad event of the Body tag, Netscape and Mozilla never seem to
update the status bar to show "Done" despite it succesfully loading the
image.

Here is a simply snippet you can use to easily reproduce this issue:

CASE A:

<html>
<body onLoad="var img = new Image(1, 1); img.src =
'http://www.mysite.com/img.gif';" >
</html>

Case A results in a status bar that indefinately shows "Transfering data
from www.mysite.com..."

Now interestingly if you change the .src so that its a relative URL instead
of absolute the problem goes away, like this:

CASE B:
<html>
<body onLoad="var img = new Image(1, 1); img.src = '/img.gif';" >
</html>

With this Case B the status bar says Done as expected and all works great.

The challenge here is that the web server that the page is running from and
the web server that I need to make the new Image .src request go to are two
different servers. So I must use the absolute URL.

I wanted to pass this additional information along however because it may
spur some ideas as to what is going on and how I can correct it.

I've tried a variety of things such as trying to clear the status bar by
forcing a window.status="" after the .src property is set, but that doesn't
help. I also tried other things such as using setTimeout to delay the .src
property being set to x milliseconds after the Body OnLoad event fires, but
in this case the same thing happens to the status bar (except that the
"Transferring data from..." message just shows up x milliseconds later.

Interestingly Firefox does not suffer from this behavior, nor does IE. It
seems specific to Mozilla and Netscape, trying the latest version of each.

Any help, tips or suggestions would be GREATLY appreciated!! Thanks so much
in advance.

--- Mike
Feb 20 '06 #1
3 4346
Mike Dee said the following on 2/20/2006 11:09 AM:
Hi,

I'm having an issue with the status bar in Mozilla and Netscape showing that
it is still waiting on the page to load even after it is finished. This
problem does NOT occur with IE.

In summary, I am using a onLoad event in the BODY tag to communicate back to
another server each time a page finishes loading. I do this by using a "new
Image()" and setting the .src property to the server. The .src includes a
value in the querystring so I know what request it was that finished
loading.

The challenge here is that the status bar still shows "Transferring data
from www.mysite.com..." despite the image being loaded. It never clears and
leaves the user with the impression that there was a problem loading the
page. My web server logs at the mysite.com show that the browser does
indeed make a request for the image and I get the querystring just fine and
it returns a status of 200 so the image is being found and served ok.

I've tried everything I can think of to solve this and really could use your
help please. Bottom line is that if you use the "new Image" statment from
within the OnLoad event of the Body tag, Netscape and Mozilla never seem to
update the status bar to show "Done" despite it succesfully loading the
image.

Here is a simply snippet you can use to easily reproduce this issue:

CASE A:

<html>
<body onLoad="var img = new Image(1, 1); img.src =
'http://www.mysite.com/img.gif';" >
</html>

Case A results in a status bar that indefinately shows "Transfering data
from www.mysite.com..."

Now interestingly if you change the .src so that its a relative URL instead
of absolute the problem goes away, like this:

CASE B:
<html>
<body onLoad="var img = new Image(1, 1); img.src = '/img.gif';" >
</html>

With this Case B the status bar says Done as expected and all works great.

The challenge here is that the web server that the page is running from and
the web server that I need to make the new Image .src request go to are two
different servers. So I must use the absolute URL.


Browser requests the image from server A, server A gets the image from
server B, server A returns the image to the Browser.

Problem solved.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Feb 20 '06 #2
> Browser requests the image from server A, server A gets the image from
server B, server A returns the image to the Browser.


Thanks. I'm not exactly seeing how this would work though. If the browser
requests the image from Server A using "new Image()" its making a request
for a .gif. So then how is server A going to act as a broker and make the
request to Server B and pass the result back to the browser?

I was thinking some more about the root cause. Maybe I can work around this
by purposely performing some other action after the image is loaded that
would some how result in the browser then realizing it was done and updating
its status line? Thoughts on this?

--- Mike
Feb 20 '06 #3
This isssue is not limited to Mozilla and Netscape. IE has the same
issue.
The Internet Explorer progress bar continues to increase when an
attached behavior is dynamically inserted in a page -
http://support.microsoft.com/default...;en-us;Q320731

Mar 1 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: abcd | last post by:
kutthaense Secretary Djetvedehald H. Rumsfeld legai predicted eventual vicmadhlary in Iraq mariyu Afghmadhlaistmadhla, kaani jetvedehly after "a ljetvedehg, hard slog," mariyu vede legai pressed...
29
by: Paul | last post by:
Hi, I'd like to limit the number of selections a user can make in a multiple select listbox. I have a note on the interface to say that only x no. of items should be selected and I check the...
2
by: Charles Mendell | last post by:
1. When I go to http://www.w3schools.com/js/default.asp and choose: 2. JS HTML DOM and then choose: 3. the Window object and then choose: 4. Write some text in the windows status bar ( a link)...
0
by: Anaam | last post by:
I have a page which is using html area and it is also uploading image files to be place in an HTML file on server side. im using ajax to send requests to server side. page works fine, image is...
55
by: Sam | last post by:
Hi, I have a serious issue using multithreading. A sample application showing my issue can be downloaded here: http://graphicsxp.free.fr/WindowsApplication11.zip The problem is that I need to...
7
by: Wayne Gibson | last post by:
Hi, I need some advise with a java applet. I am nearing completing of the project and am getting a little concerned how long it is taking for the applet to load. I have developed the java applet...
9
by: Simon Wigzell | last post by:
I have a little asp progress bar window that I open up with javascript, sized and located, all the extras turned off. It works by refreshing itself every second and displaying how much a file...
19
by: Frances | last post by:
Firefox is not respecting window.status, examples in this pg http://www.csua.berkeley.edu/~jgwang/jsform02.htm are ignored by Firefox.. why is this.. is there a solution.. thank you.. Frances
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.