Question

I'm coding a project discussion. My problem is when any member post comment to thread. That comment should be showed without reload page (As facebook). My PM does not allow me to use AJAX. So, please show what should I do to resolve this problem. Thank for help.

Was it helpful?

Solution

You have to choice to make realtime web-apps

1. Websocket : Read more in https://developer.mozilla.org/en-US/docs/WebSockets
2. Server-Sent event :https://developer.mozilla.org/en-US/docs/Server-sent_events/Using_server-sent_events

OTHER TIPS

That's really very vague.

Assuming: you mean javascript in client browser has to show data from some server without using xmlHttpRequest, then you could use a WebSocket to some ws:chat server.

Assuming you just have to put "Hello there" into a page without reloading it, I think you are asking for:

in the HTML: <div id="mymsg">-message-goes-here-</div>

in the javascript: document.getElementById('mymsg').innerHTML= "Hello there";

Yours, TonyWilk

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top