wangsisi 发表于 2010-12-21 13:50:04

MediaWiki页脚



页脚文字设置在Mediawiki的的模板中,例如/skins/MonoBook.php,页脚是通过下面的代码设置的:
$footerlinks = array(
      'lastmod', 'viewcount', 'numberofwatchingusers', 'credits', 'copyright',
      'privacy', 'about', 'disclaimer', 'tagline',
);

根据需要可以添加和删除上面的每一项内容。下面具体说明每一项的含义以及设置方法:
lastmod - 最后修订,通过编辑 MediaWiki:Lastmodifiedat (版本 1.8 或更新) 或者 MediaWiki:Lastmodified (版本 1.7 and 更老)来修改显示的内容. 如果$wgMaxCredits 启用(设置要显示几位最后的编辑者), 那么通过编辑 MediaWiki:Lastmodifiedatby (verison 1.8 and after) 或者 MediaWiki:Lastmodifiedby (version 1.7 and before)来修改。$wgMaxCredits 不启用,仅显示最后的修正日期,启用以后会显示最后的修正日期已经最后几位编辑者(显示几位编辑者通过$wgMaxCredits设置)。

viewcount - 页面的浏览次数,通过编辑 MediaWiki:Viewcount页面来修改。

numberofwatchingusers - 关注用户,通过编辑 MediaWiki:Number 来修改显示方式. 只有在LocalSettings.php中设置 $wgPageShowWatchingUsers = true; 以后才会显示这项内容。

copyright - 版权edit MediaWiki:Copyright. The parameter $1 on that page is replaced with a link to the details of copyright for your wiki. In LocalSettings.php $wgRightsText for the link text and set either $wgRightsPage or $wgRightsUrl with the location of a wiki page or external URL.

privacy - 隐私政策this is a link only. Edit MediaWiki:Privacy for the link text and MediaWiki:Privacypage for the wiki page to which to link.

about -关于 this is a link only. Edit MediaWiki:Aboutsite for the link text and MediaWiki:Aboutpage for the wiki page to which to link.

disclaimer - 免责声明this is a link only. Edit MediaWiki:Disclaimers for the link text and MediaWiki:Disclaimerpage for the wiki page to which to link.
tagline - 目前没有使用


页脚图片设置左侧图片: copyright图标, 通过 $wgCopyrightIcon进行设置,设置方法如下:在LocalSettings.php 文件中设置$wgCopyrightIcon,例如本站的设置是:

$wgCopyrightIcon = '<a href="http://www.zzbaike.com"><img src="images/zzbaike.gif" width="117" height="37" alt="站长百科" /></a>';

设置的时候注意内层和外层不能同时用双引号,内层用单引号或者是外层用单引号,否则会引起unexpected T_CONSTANT_ENCAPSED_STRING 的错误。
右侧图片: poweredby图标
页: [1]
查看完整版本: MediaWiki页脚

美国HostEase虚拟主机一年198元