Manual:$wgNamespacesToBeSearchedDefault

From MediaWiki.org
Jump to: navigation, search

Other languages:
English • ‎français • ‎日本語 • ‎русский
Namespaces: $wgNamespacesToBeSearchedDefault
Which namespaces should be searched?
Introduced in version: pre 1.1.0
Removed in version: still in use
Allowed values: see below
Default value: see below
Other settings: Alphabetical | By function

Details[edit]

The variable holds an array of namespaces, indicating which namespaces are enabled for searching by default. The array is indexed by the namespace constant. Namespaces not added will not be searched by default.

Default value[edit]

$wgNamespacesToBeSearchedDefault = [
	NS_MAIN => true,
];

Adding namespaces[edit]

To add other namespaces you just add this to you "LocalSettings.php" file, e. g. for the project namespace:

$wgNamespacesToBeSearchedDefault[NS_PROJECT] = true;

Changing options for existing users[edit]

MediaWiki version: 1.16

In MediaWiki 1.16 and later, you do not have to change options for existing users.