Jump to content

Extension:TitleKey: Difference between revisions

From mediawiki.org
Content deleted Content added
included in Miraheze
No edit summary
Line 31: Line 31:
|db-update=Yes
|db-update=Yes
|custom-steps=* <translate><!--T:8--> Run the "rebuildTitleKeys.php" script (this requires command-line access):</translate>
|custom-steps=* <translate><!--T:8--> Run the "rebuildTitleKeys.php" script (this requires command-line access):</translate>
: <syntaxhighlight lang="bash">php extensions/TitleKey/maintenance/rebuildTitleKeys.php</syntaxhighlight>
: <syntaxhighlight lang="bash">MW_INSTALL_PATH=/path/to/mediawiki php extensions/TitleKey/maintenance/rebuildTitleKeys.php</syntaxhighlight>
|registration=Yes
|registration=Yes
|no-registration-version=1.27
|no-registration-version=1.27
Line 37: Line 37:


<translate>
<translate>

== Known problems == <!--T:9-->
== Known problems == <!--T:9-->



Revision as of 22:53, 2 February 2023

MediaWiki extensions manual
TitleKey
Release status: stable
Implementation Search
Description Provides a case-insensitive page title prefix search
Author(s) Brion Vibber (Brion VIBBERtalk)
Latest version continuous updates
MediaWiki 1.25+
Database changes Yes
Tables titlekey
License GNU General Public License 2.0 or later
Download
README
Quarterly downloads 62 (Ranked 70th)
Translate the TitleKey extension if it is available at translatewiki.net
Issues Open tasks · Report a bug

The TitleKey extension provides a case-insensitive page title prefix search. It uses a separate table for the keys, so it can be deployed without an expensive rebuild of core tables, and uninstalled later in preference for a different search extension such as CirrusSearch .

For the average site administrator, the benefit of this extension is that it allows search suggestions (e.g. from Opensearch API) to be case-insensitive.

This extension provides no benefit if you are using CirrusSearch .

Installation

  • Download and move the extracted TitleKey folder to your extensions/ directory.
    Developers and code contributors should install the extension from Git instead, using:cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/TitleKey
  • Add the following code at the bottom of your LocalSettings.php file:
    wfLoadExtension( 'TitleKey' );
    
  • Run the update script which will automatically create the necessary database tables that this extension needs.
  • Run the "rebuildTitleKeys.php" script (this requires command-line access):
MW_INSTALL_PATH=/path/to/mediawiki php extensions/TitleKey/maintenance/rebuildTitleKeys.php
  • Yes Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.


Known problems

  • It breaks VisualEditor autocompletion for templates (see topic).
  • It breaks any extension that relies on Prefixsearch which also includes TemplateWizard .
  • With MediaWiki 1.35 or earlier it breaks search suggestions for pages that are not in the main namespace. (The Gerrit patch fixing this issue has been released as part of MediaWiki 1.36: Gerrit change 641277.)