Extension:FeaturedFeeds/fr

From Linux Web Expert

Manuel des extensions MediaWiki
FeaturedFeeds
État de la version : stable
px
Implémentation Extraction de données, API , Accroche
Description Adds syndication feeds of wiki's featured content
Auteur(s) Max Semenik (MaxSemtalk)
Dernière version continuous updates
MediaWiki 1.19+
PHP 5.4+
Modifie la base
de données
Non
Licence Aucune licence spécifiée
Téléchargement
CHANGELOG
Téléchargements trimestriels Lua error in Module:Extension at line 172: bad argument #1 to 'inNamespace' (unrecognized namespace name 'skin').
Utilisé par les wikis publics Lua error in Module:Extension at line 172: bad argument #1 to 'inNamespace' (unrecognized namespace name 'skin').
Traduire l’extension FeaturedFeeds sur translatewiki.net si elle y est disponible
Problèmes Tâches ouvertes · Signaler un bogue

FeaturedFeeds is an extension that creates daily feeds (Atom or RSS) of wiki's featured content (ranging from Featured Articles to Media of the Day). The feeds are added to site's main page and are available via the featuredfeed API module. See also: Extension:FeaturedFeeds/WMF deployment .

Using FeaturedFeeds

This extension requires that wikis use an automated process to publish their featured content daily (or at least very often).

Installation

  • <translate> [[<tvar name=2>Special:ExtensionDistributor/FeaturedFeeds/fr</tvar>|Download]] and move the extracted <tvar name=name>FeaturedFeeds/fr</tvar> folder to your <tvar name=ext>extensions/</tvar> directory.</translate>
    <translate> Developers and code contributors should install the extension [[<tvar name=git>Special:MyLanguage/Download from Git</tvar>|from Git]] instead, using:</translate>cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/FeaturedFeeds%2Ffr
  • <translate> Add the following code at the bottom of your <tvar name=1>LocalSettings.php </tvar> file:</translate>
    wfLoadExtension( 'FeaturedFeeds/fr' );
    
  • File:OOjs UI icon check-constructive.svg <translate> Done</translate> – <translate> Navigate to <tvar name=special>Special:Version</tvar> on your wiki to verify that the extension is successfully installed.</translate>

Configuration

A wiki must have some means of caching set up to use FeaturedFeeds, or everything will be super slow.

Settings

Variable name Description
$wgFeaturedFeeds Contains array of feed definitions in the following format:
'feed name' => [
	'page' => <message name>,
	'title' => <message name>,
	'description' => <message name>,
	'entryName' => <message name>,
]

Mandatory items:

'page'
Name of the interface message that contains an expression that evaluates to the title of the page with today's feed entry. For example, for English Wikipedia's featured articles feed it could contain Wikipedia:Today's featured article/{{#time:F j, Y}} that evaluates (using ParserFunctions, but ordinary date/time magic words may be used as well) to Wikipedia:Today's featured article/April 24, 2025. This message always uses content language.
'title'
Name of the interface message that contains feed title, for example "My Page of the Day Feed".
'description'
A longer description of the feed, used for ‎<subtitle> Atom element, and ‎<description> RSS element.
'entryName'
Name of the interface message that contains heading of feed's individual entries.

Also see below for optional settings.

$wgFeaturedFeedsDefaults Provides default values for some parameters of every feed from $wgFeaturedFeeds.

Default value:

[
	'limit' => 10,
	'inUserLanguage' => false,
]
'limit'
Maximum number of entries (ie number of days) in the feed.
'inUserLanguage'
Whether user's preferred language should be honored by the feed. For example, it doesn't make much sense to have English Wikipedia's featured articles feed in languages other than English as the content is always in English anyway. But Commons' picture of the day feed contains images and their descriptions that are available in many languages, so it actually benefits from its description's localisation.
$wgDisplayFeedsInSidebar Whether links to feeds should be displayed in sidebar on main page

On-site configuration

See the full subpage for details on the Wikimedia projects configuration

{{#lst:Extension:FeaturedFeeds/WMF deployment|messages}}

API module

www.linuxwebexpert.com has no featured feeds, so the generated API documentation on this wiki is not very useful.

Instead, see the generated API documentation on enwiki, which lists the feeds it provides and has a working example.