Jump to content

User:GhostInTheMachine/SubPages

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by GhostInTheMachine (talk | contribs) at 18:40, 29 June 2020 (Add documentation for SubPages user script). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
(diff) ← Previous revision | Latest revision (diff) | Newer revision → (diff)

GhostInTheMachineTalkAllBarnstarsHelpMiscModulesOtherLayoutPhotosProjectsScriptsTidyingTidyingSDUBXWIP2020-06-29 18:40:20

Purpose

This script adds a button to the page menu to navigate to the special page which lists the subpages.

Prerequisites

None.

Use

The script adds the Subpages button after the Talk button on the page menu.

Articles in the main namespace cannot have subpages, so the button is not displayed for articles.

Installing

Add the following line to your common.js file.

{{subst:lusc|User:GhostInTheMachine/SubPages.js}}

Possible improvements

  • Do not display the button for category pages or files.
  • Test for subpages and then only display the button if some are found.

See also