Extension:Dynamic Article List

From MediaWiki.org
Jump to: navigation, search
MediaWiki extensions manualManual:Extensions
Crystal Clear action run.png
Dynamic Article List

Release status:Extension status beta

Sample Dynamic Article List 1.png
ImplementationTemplate:Extension#type Tag
DescriptionTemplate:Extension#description Provide add-on sort ability among all posted articles on four types of Dynamic Article List
Author(s)Template:Extension#username Zengji, Onestone
Latest versionTemplate:Extension#version 2.0 (2013-05-01)
MediaWikiTemplate:Extension#mediawiki 1.20+
PHPTemplate:Extension#php 5+
Database changesTemplate:Extension#needs-updatephp No
LicenseTemplate:Extension#license No license specified
Download external DOWNLOAD
TagsTemplate:Extension#tags
<DynamicArticleList>

Translate the Dynamic Article List extension if it is available at translatewiki.net

Check usage and version matrix.

DynamicArticleList is an extension designed to provide add-on sortability among all posted articles. Now four types of Dynamic Article List have been implemented:

  1. Newly Posted Articles
  2. Recently Updated Articles
  3. Recent Discussions
  4. Most Popular Articles

User could easily find the latest or most popular topics cross site with the help of Dynamic Article List.

This extension is written with the help from Dynamic Page List.

As of MW 1.26.0 page counters are no longer available in MW core. Therefore, the functionality for most popular articles is broken. Obsolescence of some API functions and lack of on-going updates by the maintainer has also resulted in PHP errors, meaning if you are trying to install this extension on MW versions > 1.26.0 you are unlikely to be able to run it 'out-of-the-box'. Updated extension code is available under the discussion tab and includes updates for the post MW 1.25.0 extension loading mechanism. At some point the maintainer may port this into the main code base.

Installation[edit]

  • Download and place the file(s) in a directory called DynamicArticleList in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php:
require_once "$IP/extensions/DynamicArticleList/DynamicArticleList.php";
  • YesY Done - Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

Usage[edit]

Tag and its parameters[edit]

Tag Name DynamicArticleList
Parameters title (optional) Title of the output article list
type (optional) Type of dynamic article list (new/update/discussion/hot)
count (optional) Output count of articles
categoryRoot (optional) Name of category where (including its children) all articles reside
  • If "categoryRoot" is set, Dynamic Article List will only retrieve articles in this category and its children. If not, all articles will be candidates.
  • The value of parameter "type" could be one of the following (default is new ):
    • new => Newly Posted Articles
    • update => Recently Updated Articles
    • discussion => Recent Discussions
    • hot => Most Popular Articles
  • The default value of "count" is 5 .

Samples[edit]

A sample snapshot of Dynamic Article List is shown below.

Sample Dynamic Article List 1.png

When "type" is set to new ,
The output record format would be Page Title (author) - [create time]
When "type" is set to update or discussion ,
The output record format would be Page Title (last editor) - [update time]

The underlying wiki codes are:


<DynamicArticleList>
  title=Newly Posted Articles
  type=new
  count=5
</DynamicArticleList>

Another sample snapshot of Dynamic Article List is shown below.

Sample Dynamic Article List 2.png

When "type" is set to hot ,
The output record format would be Page Title - (accessed times)

The underlying wiki codes are:


<DynamicArticleList>
  title=Most Popular Articles
  type=hot
  count=5
</DynamicArticleList>