扩展:APNG

From MediaWiki.org
Jump to navigation Jump to search
This page is a translated version of the page Extension:APNG and the translation is 36% complete.

Other languages:
Deutsch • ‎English • ‎español • ‎français • ‎polski • ‎中文 • ‎日本語
MediaWiki扩展手册
OOjs UI icon advanced.svg
APNG
发布状态: 测试
实现 Media
描述 Enables animated PNG support in unsupported browsers, based on apng-canvas library.
作者 Mudkip metalk
最新版本 0.2.0 (2018-01-07)
MediaWiki 1.25+
PHP 5.3+
数据更新
许可协议 MIT License
下载
README
例子 http://wiki.52poke.com/wiki/七賢人
翻译APNG扩展如果在translatewiki.net可用
检查使用和版本矩阵。

The APNG extension enables animated PNG support in unsupported browsers.

Currently, the only modern browser without APNG support is Microsoft Edge. This extension works on all modern browsers and IE starting with version 10.

APNG extension is based on David Mzareulyan's apng-canvas library.

安装

  • 下载文件,并将其放置在您extensions/文件夹中的APNG目录内。
  • 将下列代码放置在您的LocalSettings.php的底部:
    require_once "$IP/extensions/APNG/APNG.php";
    
  • Yes 完成 – 在您的wiki上导航至Special:Version,以验证扩展已成功安装。

限制

If you use a different domain for your $wgUploadPath, the web server is required to send a Access-Control-Allow-Origin: * header for PNG files.

For example, you can simply add the following lines to the location scope of your Nginx configuration:

    if ($request_uri ~* \.png$) {
        add_header Access-Control-Allow-Origin *;
    }