This page is a translated version of the page Extension:RottenLinks and the translation is 38% complete.
MediaWiki扩展手册
RottenLinks
发行状态: 稳定版
描述 Provides the Special page Special:RottenLinks.
作者 John Lewis, Universal Omega
维护者 Miraheze system administrators
最新版本 continuous updates
MediaWiki 1.39+
PHP 7.2+
数据库更改
Composer miraheze/rotten-links
许可协议 GNU通用公眾授權條款3.0或更新版本
下載
README
CHANGELOG

  • $wgRottenLinksBadCodes
  • $wgRottenLinksCurlTimeout
  • $wgRottenLinksExcludeProtocols
  • $wgRottenLinksExcludeWebsites
  • $wgRottenLinksExternalLinkTarget

The RottenLinks extension provides the special page "Special:RottenLinks", which shows a table of all external links on your wiki pages, and tells you their status.

For reporting an issue or a bug, please use Miraheze Phabricator. See here for the workboard.

安裝

  • 下载文件,并将其放置在您extensions/文件夹中的RottenLinks目录内。
  • 将下列代码放置在您的LocalSettings.php 的底部:
    wfLoadExtension( 'RottenLinks' );
    
  • 运行更新脚本,它将自动创建此扩展必须依赖的数据库表。
  • 按需求配置。
  • Run the following script to populate the special page "Special:RottenLinks":
    php extensions/RottenLinks/maintenance/updateExternalLinks.php
    
  •   完成 – 在您的wiki上导航至Special:Version,以验证已成功安装扩展。

If you would like to use RottenLinks with MediaWiki 1.39, you have to use the REL1_39 branch.

配置

$wgRottenLinksBadCodes
Holds a list of HTTP codes that are considered bad. 默认值为“[ "0", "400", "401", "403", "404", "405", "502", "503", "504" ]”。
$wgRottenLinksCurlTimeout
Sets the timeout for cURL in seconds. 默认值为“30”。
$wgRottenLinksHTTPProxy
Sets a proxy to use for requests. Defaults to "" (use no proxy). Example: $wgRottenLinksHTTPProxy = "http://username:password@proxy.example.com:8080";
$wgRottenLinksExcludeProtocols
Holds a list of protocols that should not be checked for validity. 默认值为“[ "tel", "mailto" ]”。
$wgRottenLinksExternalLinkTarget
Sets the external link target (_self for the current tab or _blank for new tab). 默认值为“_self”。
$wgRottenLinksExcludeWebsites
List of websites to blacklist checking of response codes for. Defaults to false. Omit the protocol, e.g. use $wgRottenLinksExcludeWebsites = [ "www.example.com" ];

用法

Run the "updateExternalLinks.php" script provided with the extension every time you would like to create or update the list of rotten links shown on special page "Special:RottenLinks".