Does anyone know how to make new posts automatically show up in the frontpage, with out having to refresh the page. I have a wordpress site with multiple authors and want their new posts to show up automatically.
Thanks.
Does anyone know how to make new posts automatically show up in the frontpage, with out having to refresh the page. I have a wordpress site with multiple authors and want their new posts to show up automatically.
Thanks.
You must be logged in to post a comment.
I cannot find a plugin that does this (although the Live Blogging Plugin is similar to what you need).
In general you should use the Periodic Refresh ajax pattern to check the server every few seconds if the content of the current dom is the latest posts. If not, insert in the content of the latest post(s). Good Luck!
In my (limited) programming world, I found
Ajax long polling
to be the easiest way of doing live updates.Here is a basic example of it:
https://stackoverflow.com/questions/333664/simple-long-polling-example-code
Other way would be to use HTML5 Websockets (but it needs special server setup):
http://net.tutsplus.com/tutorials/javascript-ajax/start-using-html5-websockets-today/