Jump to content

Main Page

From DynamicPageList4 Manual
Manual

DynamicPageList4 (DPL4) is a powerful MediaWiki extension that generate lists of pages, page properties (metadata), and/or template parameter values, for display in other articles. DPL4 lists are automatically updated whenever the data it fetches changes and the cache is cleared or expires. The output can be formatted to create a range of displays from lists (the default format), to in-line paragraph text/content, tables, galleries, navigation, and many other possibilities.

As a basic example, DPL4 can be used to insert in a wiki page, an always-current list of all pages of a particular category. The data displayed may be selected and sorted based on factors like author, namespace, date, name pattern, usage of templates, or references to other articles, with a variety of custom formatting.

Installation

[edit source]
  • For Miraheze (WikiFarm) users, the DPL4 MediaWiki extension is already installed, it simply needs to be enabled by a user with the appropriate privileges in ManageWiki.
  • Other users should see the MediaWiki software DynamicPageList4 Extension installation page section for information on how to install the extension in MediaWiki.

Configuration

[edit source]

DPL4 has a variety of configuration settings that can be used, as well as a number of defaults that are important to note. Settings should be defined before enabling the extension.

Limiting results and resource consumption

[edit source]

To prevent a DPL4 query from returning huge output (or consuming too many resources such as CPU or causing database load). The following configuration variables are noteworthy:

Setting Default Description
$wgDplSettings['maxCategoryCount'] 8 Limits the number of categories allowed in queries (default is 8).
$wgDplSettings['maxQueryTime'] 10000 Limits the time amount (in milliseconds) allowed for database queries.
$wgDplSettings['maxResultCount'] 500 Limits the number of results returned in a query (default is 500).
$wgDplSettings['runFromProtectedPagesOnly'] false Causes DPL4 to only run from protected pages (if set to true), which can aid administrators having problems with malicious user activity resulting in computationally expensive queries.

Note: For Miraheze users, these settings are set automatically and can not be currently changed except by request.

Functional richness

[edit source]

DynamicPageList4 has different levels of functional richness, which can be configured as needed. Higher levels of functionality should be considered carefully and used sparingly.

Note: For Miraheze users, these settings are set automatically and can not be currently changed except by request.

Setting Value Description
$wgDplSettings['functionalRichness'] 0 Provides functionality equivalent to Wikimedia's DynamicPageList (also known as Intersection).
$wgDplSettings['functionalRichness'] 1 Adds additional parameters for formatting.
$wgDplSettings['functionalRichness'] 2 Adds features (performance equivalent) for pagelinks and templates.
$wgDplSettings['functionalRichness'] 3 Allows more-expensive inclusion features, such as queries on revision level, and regular expression queries (default).
$wgDplSettings['functionalRichness'] 4 Not recommended for public websites. Includes debugging parameters for testing and development.
Important: Some levels of functional richness can cause high database or CPU load, and should be carefully considered.
Setting Default Description
$wgDplSettings['allowedNamespaces'] [] All existing namespaces are used by default when DPL4 is initialized. An array of namespace constants can be provided to restrict DPL4 to only working in the specified namespaces.
$wgDplSettings['allowUnlimitedCategories'] false Ignores 'maxCategoryCount' and allows unlimited categories, if set to true. Note that large numbers of categories in queries can cause servers to slow or crash.
$wgDplSettings['allowUnlimitedResults'] false Ignores 'maxResultCount' and allows unlimited results, if set to true. Note that large sets of results may cause pages to slow or fail to load.
$wgDplSettings['alwaysCacheResults'] false Ignores 'allowcachedresults' and enables the parser cache, if set to true.
$wgDplSettings['categoryStyleListCutoff'] 6 Maximum number of items permitted in a category list, additional are cut off.
$wgDplSettings['minCategoryCount'] 0 Minimum number of categories permitted in DPL4 queries.
$wgDplSettings['overrideParameterDefaults'] [] An associative array of parameter names and their override values. These values replace the default parameter values defined in ParametersData, but only if the current defaults differ.
$wgDplSettings['queryCacheTime'] 0 Specifies the amount of time to cache a query for, the query cache then cannot be purged. Values between 30 and 600 are suggested.
$wgDplSettings['recursivePreprocess'] true Use Parser::recursivePreprocess() to improve performance by preserving the internal cache, reducing redundant template parsing.
$wgDplSettings['recursiveTagParse'] false Performs recursive parsing on open parser tags, converting tags and functions (for example, magic words like {{PAGENAME}}). Though it may not work the same in all cases, this functions similarly to the {{#dpl}} DPL4 parser function (see Other Modules).

The General use and invocation syntax page is essential to read, to understand the fundamentals of DPL4 use, it is not recommended to skip this section of the manual.

Primary DPL4 module

[edit source]

These sections contain documentation on DPL4's primary module. This is the DPL4 functionality used most often, and has a wide range of powerful coding options.

Other DPL4 modules

[edit source]

These sections detail some additional functions provided by the DPL4 extension.

More information

[edit source]
Cookies help us deliver our services. By using our services, you agree to our use of cookies.