Jump to content

Extension:HitCounters/fr

From mediawiki.org
This page is a translated version of the page Extension:HitCounters and the translation is 20% complete.
Outdated translations are marked like this.
Manuel des extensions MediaWiki
HitCounters
État de la version : stable
Implémentation Base de données , Extraction de données, MyWiki
Description Provides a page views functionality
Auteur(s) Mark A. Hershberger (MarkAHershbergerdiscussion)
Dernière version 0.4
MediaWiki >= 1.36.0
PHP 7.3.19+
Modifie la base
de données
Oui
Composer mediawiki/hit-counters
Tables hit_counter
hit_counter_extension
Licence Licence publique générale GNU v3.0 ou supérieur
Téléchargement
  • $wgDisableCounters
  • $wgHitcounterUpdateFreq
  • $wgEnableAddPageId
  • $wgEnableAddTextLength
hitcounter-exempt
Téléchargements trimestriels 149 (Ranked 43rd)
Traduire l’extension HitCounters sur translatewiki.net si elle y est disponible
Rôle Vagrant hitcounters
Problèmes Tâches ouvertes · Signaler un bogue

The HitCounters extension displays the view count in the page footer and the most viewed pages on a special page called PopularPages. The extension provides page views statistics that were removed in MediaWiki 1.25 .

À propos

Benefits

This extension provides feedback in the form of audience measurement to editors. Knowing the rough size of one's audience as an editor allows editors to identify and improve popular articles. HitCounters' special page PopularPages also allows editors to focus on improving those articles with the highest traffic and helps readers discover a project's most curated content.

HitCounters extension enables determining the wikiFactor, a rough measure of a wiki website's popularity.

HitCounters extension is minimally intrusive concerning data security and privacy concerns. The extension handles metrics on the server side, so aggregated data stays within the site's security boundary. The extension does not inject JavaScript to be executed by the client and does not ask a client to download additional un-audited code from a third party, like GoogleAnalyticsMetrics .

The extension does not track users who visit a page. As such, there's no need for special handling of "Do Not Track" browser requests or Global Privacy Control settings. The extension also does not use third-party services like the GoogleAnalyticsMetrics extension.

The extension has no dependencies that can cause conflicts. Other extensions, like GoogleAnalyticsMetrics, can cause problems during a Composer update. Also see P6481.

Différences fde l'implémentation dans le noyau MediaWiki

Before MediaWiki 1.25, the page views counting functionality was in core MediaWiki. This extension is based on that same code but was deliberately made lighter to speed up processing time. Many lines of superfluous code were removed. Also, the old MediaWiki core code performed numerous database queries on every page hit; these have all been removed. This change may lead to some inaccuracies in the data.

The core differences that wiki administrators need to know are:

  • The hit counts are stored in the cache.
  • The visible hit count at the bottom of each page is updated only once daily. (Pages with a hit count of less than 100 are updated once per minute.)
  • That hit is ignored if you refresh your browser on a wiki page.

Ce qui est pris en compte pour une vue

According to tests conducted by several MediaWiki operators, a view is counted if a page is accessed (action=view), as well as action=render and when accessing a page revision.

A view is not counted with the other actions, such as action=raw, action=edit, and action=info.

Migration

If you are migrating from a version of MediaWiki 1.25 and earlier to a newer version, you must ensure to follow the advice and documentation outlined in this version of the documentation.

Installation

  • Téléchargez et placez le(s) fichier(s) dans un répertoire appelé HitCounters dans votre dossier extensions/.
    Les développeurs et les contributeurs au code doivent à la place installer l'extension à partir de Git en utilisant:cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/HitCounters
  • Ajoutez le code suivant à la fin de votre fichier LocalSettings.php  :
    wfLoadExtension( 'HitCounters' );
    
  • Exécutez le script de mise à jour qui va créer automatiquement les tables de base de données dont cette extension a besoin.
  • Configure as required.
  • Yes Fait – Accédez à Special:Version sur votre wiki pour vérifier que l'extension a bien été installée.


Installation Vagrant :

  • Si vous utilisez Vagrant , installez avec vagrant roles enable hitcounters --provision

Note Note :

Configuratio

  • $wgDisableCounters
    When set to true, it disables the notice in the pages footer saying "Cette page a été consultée 256 fois." as well as the special page "PopularPages". The default value is false.
  • $wgHitcounterUpdateFreq
    Sets how often page counters should be updated. The default value is 1.
  • $wgGroupPermissions['sysop']['hitcounter-exempt'] = true;
    Exclude user group page views from counting.
  • $wgEnableAddPageId
    When set to true, it adds the PageId to the special page "PopularPages". The default value is false.
  • $wgEnableAddTextLength
    When set to true, it adds the TextLength to the special page "PopularPages". The default value is false.

Fork

There is a fork of this extension that offers custom settings to the user:

See also