Forum Moderators: open

Message Too Old, No Replies

A cross-domain Ajax problem for the advanced

         

SnowDevil

4:18 am on Jun 13, 2006 (gmt 0)

10+ Year Member



Hey people,

Ok so I have an annoying problem I'm unsure how to resolve. I'm employing the dynamic script tag technique to achieve cross-domain Ajax calls, and it works just fine. This problem crops up though because I am polling a remote server every five seconds. In Internet Explorer I have no complaints at all. Firefox, however, displays a "waiting for [remote server]..." message every time a call is made. In a polling scenario this becomes annoying and looks unprofessional. I can't have a "waiting for..." message flash in the status bar every five seconds. There are other ways to poll the server, but in my case I actually care about the response as it may occasionally contain a small snippet of JavaScript that I want to execute.

So the question is, how do I execute a cross-domain Ajax call in Firefox that *doesn't* generate a status bar "waiting" message?

kadnan

4:57 am on Jun 13, 2006 (gmt 0)

10+ Year Member


AFAIK.IE is not giving you message because its using cache for getting data while FF by default fetches new page everytime.

Apply cache technique on your backend script,you will be able to see same message on IE as well.

-adnan

SnowDevil

5:09 am on Jun 13, 2006 (gmt 0)

10+ Year Member



Nah, caching can't be the problem for two reasons. First, the server-side script which writes out the javascript response is preventing caching. Secondly, IE is correctly polling the server every few seconds as designed. This polling updates a database record each hit. I can see the record being updated, hence IE is not caching the response.

visionmonster

1:46 pm on Jun 13, 2006 (gmt 0)

10+ Year Member



did you try and trash the window.status message after you refresh the call to the js?

jshanman

3:19 pm on Jun 13, 2006 (gmt 0)

10+ Year Member



did you try and trash the window.status message after you refresh the call to the js?

In Firefox, the developer no longer has control over the window.status message.

So the question is, how do I execute a cross-domain Ajax call in Firefox that *doesn't* generate a status bar "waiting" message?

My guess is that you'd have to create a custom extension that supresses the default action. I can't think of any other way because it isn't a scripting issue, it's a browser implementation issue.

- JS