Jump to content

Topic on Project:Support desk/Flow

[RESOLVED] Is it possible to force MediaWiki update a certain Category:XXX page?

7
194.44.30.5 (talkcontribs)

Hi.

Is it possible to force MediaWiki update a certain Category:XXX page? For example, a lot of pages used templates that referred a category "Templates" causing every such page to be included to the "Template" category. That's obviously wrong. I have already fixed the templates by wrapping the "Templates" category into the noinclude tag, so now every page that use these templates are no longer categorized as "Templates". That's fine.

   Article source:
       {{stub}}
   
   Template source BEFORE the fix:
       This page is a stub
       [[Category:Templates]]
   Rendered article BEFORE the fix:
       This page is a stub
       Categories: Templates | Stubs
   Category Templates BEFORE the fix:
       Article
       Template:Stub
   
   Template source AFTER the fix:
       This page is a stub
       <noinclude>[[Category:Templates]]</noinclude>
   Rendered article AFTER the fix:
       This page is a stub
       Categories: Stubs
   Category Templates AFTER the fix:
       Article <--- this is wrong
       Template:Stub

But the list in the Category:Template seems to be frozen for really long time. I do remember that I had a similar case a half year ago, and I clearly watched the number of pages decreased slowly, but constantly. Now it got stuck. Is any categorization update status page available? (I'm almost sure that I remember someone told me it's performed by a background job) Or what am I doing wrong?

  • MediaWiki: 1.23.6
  • PHP: 5.4.38

Thanks in advance.

88.130.116.172 (talkcontribs)

refreshLinks.php allows you to update the content of category pages. The case that categories show wrong pages inside themselves, is exactly what this script was made for.

194.44.30.5 (talkcontribs)

Thank you! Is it possible to invoke the script using the web-front end? I don't have access to run PHP scripts directly.

88.130.116.172 (talkcontribs)

This script is not intended to be called via the browser. Anyway, there is Extension:MaintenanceShell, which according to its description here on MediaWiki.org does allow you to run shell commands that way. Note that I have not tested this extension and note that you should remove it directly after usage - basically it is a security risk.

195.234.75.155 (talkcontribs)

Security risks aren't cheap, that's true. I have no access to the local settings file to install the extension (if I'd have, I'd run that PHP script directly). But it's really good to know. Thank you very much!

Ricordisamoa (talkcontribs)

Not sure, but you could purge the template page via the purge API with the forcerecursivelinkupdate parameter.

195.234.75.155 (talkcontribs)

Good to know, thank you! I'll remember this suggestion for the future since I've already fixed the issue using null-edits.