Map a field on the page to an ajax request. When the response is returned it will be displayed in the field.
Open a connection to the server, send a $.ajax GET request, wait for a response with the message, and display the message.
Place a $.ajax GET request in a loop. If the GET request returns a message, display it. Sleep for a period and then loop back to do the GET request again to see if there is a new message.
|