How to autoupdate a forum thread when new posts?

Greasemonkey plugin. (js/ajax, jquery optional).

  • Want to autoupdate forum pages when they get changed (new posts, for instance). Ideally with no page refresh.
  • Additionally, if I can make it load multi-page threads in one page (when applicable, perfect).
  • Don't want to lose content in response boxes if there's any text in them.
  • Site: Paizo.com.

How would you guys go about doing this?

Answers:

Answer

loop GM_xmlhttpRequest to get the forum page in a 15 minutes interval.
save the response, and compare with the last one.
keep only the content that was added, and display it any way you see fit (i would use a div).

in this example here you can see how to use GM_xmlhttpRequest, create a DIV on the fly, store the desired content into it, and use its data as a parameter to request another page with GM_xmlhttpRequest again, repeating the cycle.

if you want me to explain the script, let me know.

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.