Extension:PageMagic

MediaWiki extensions manual
OOjs UI icon advanced.svg
PageMagic
Release status: beta
Description The extension adds a few parser functions to retrieve page id by name and vice versa.
Author(s) (vedmakatalk)
Maintainer(s) WikiTeq team
Compatibility policy For every MediaWiki release that is a Long Term Support release there is a corresponding branch in the extension.
MediaWiki 1.31+
License GNU General Public License 2.0 or later
Download
README
Translate the PageMagic extension if it is available at translatewiki.net

Check usage and version matrix.

Issues Open tasks · Report a bug

The PageMagic extension adds a few parser functions to retrieve page id by name and vice versa.

This extension was created for WikiWorks.

InstallationEdit

  • Download and place the file(s) in a directory called PageMagic in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php :
    wfLoadExtension( 'PageMagic' );
    
  •   Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

UsageEdit

The following magic words are introduced:

  • FULLPAGENAMEFROMID - converts provided page id into a full page name
  • PAGEIDFROMREVISIONID - converts provided revision id into a page id
  • FULLPAGENAMEFROMREVISIONID - converts provided revision id into a full page name

Examples:

{{FULLPAGENAMEFROMID:12345}} -> Namespace:Pagename
{{PAGEIDFROMREVISIONID:3456}} -> 12345
{{FULLPAGENAMEFROMREVISIONID:3456}} -> Namespace:Pagename

Also, see the README.

See alsoEdit

  This extension is professionally maintained by the WikiTeq team.