Forum:Refresh

How to add that little option check box that said something like "automatic Refresh" into a page? Mand&#39;alor Skyobiliviator The Devastator 02:59, September 25, 2011 (UTC)


 * See here--
 * I don't get it. Can you explain to me? I want this on one normal page, not on recent activities, or that such... Mand&#39;alor Skyobiliviator The Devastator 06:43, September 25, 2011 (UTC)


 * Add importScriptPage('AjaxRC/code.js', 'dev'); to MediaWiki:Common.js and also add ajaxPages = ["NameOfPageOne","NameOfPageTwo"]; to Common.js. Make sure to replace NameOfPage# with the page(s) you want. If you only want it on one page, remove the ,"NameOfPageTwo" part.
 * Thanks, now how to adjust the reload time? Sorry for delay, have to block somebody. Mand&#39;alor Skyobiliviator The Devastator 07:04, September 25, 2011 (UTC)


 * Add this: var ajaxRefresh = #000; to Common.js, change # to how many seconds you want the reload time to be.
 * When you put in the page names, do you want to keep the quotations(" ")?Mand&#39;alor Skyobiliviator The Devastator 07:14, September 25, 2011 (UTC)


 * Yes.
 * How long does it take to become active? Mand&#39;alor Skyobiliviator The Devastator 07:21, September 25, 2011 (UTC)

Keep clearing your cache and it should work after a few minutes. Also, if the page name has spaces, you have to use _ instead of a space in the page name in the JS.


 * Okay, isn't 01000 = to 1 sec? Mand&#39;alor Skyobiliviator The Devastator 07:31, September 25, 2011 (UTC)

1000 is 1 second.