How to display an AJAX progress bar / message
I don't necessarily need a progress bar, what I need is a way to update the progress message being shown to the user from the server.. without the javascript repeatedly requesting an update from the server.

For example:

- User clicks a 'Submit' button
- A message shows up 'Processing X/100'
- Then the message automatically updates itself with 'Processing 2/100, 3/100, etc' automatically.

What I would like, is that a connection to the server is maintained throughout the request, and whenever the server pushes out a new status message, the javascript receives it and updates the progress message, until the server gives the message that 100/100 processed, and then the javascript terminates the connection.

Essentially I'm looking for the technique Gmail, Facebook etc use to 'push' data from the server and having the client get updated, without the client requesting an update from the server like its normally done.

Any thoughts?
How to display an AJAX progress bar / message
===

I don't necessarily need a progress bar, what I need is a way to update the progress message being shown to the user from the server.. without the javascript repeatedly requesting an update from the server.

For example:

- User clicks a 'Submit' button
- A message shows up 'Processing X/100'
- Then the message automatically updates itself with 'Processing 2/100, 3/100, etc' automatically.

What I would like, is that a connection to the server is maintained throughout the request, and whenever the server pushes out a new status message, the javascript receives it and updates the progress message, until the server gives the message that 100/100 processed, and then the javascript terminates the connection.

Essentially I'm looking for the technique Gmail, Facebook etc use to 'push' data from the server and having the client get updated, without the client requesting an update from the server like its normally done.

Any thoughts?