ArticleComments
天下维客,你可以修改的网络知识库
| Template:If | |
| Type: | parser |
|---|---|
| Maturity: | {{{maturity}}} |
| MediaWiki: | 1.6.x, 1.8.x, 1.9.x |
| Version: | 0.4 |
| Last Update: | {{{update}}} |
| Description: | 插入一个类似博客的评论页的区块到你的文章中. |
| MediaWiki extensions | |
ArticleComments 可以让你快速插入一个类似博客的评论页的区块到你的文章中.
请及时查看项目主页以便获得更新的信息.
- 项目主页
- ArticleComments Extension - Jimbojw.com
- 源码
- ArticleComments.php
- 演示
- ArticleComments Test Page (try before you buy)
- Licensing
- ArticleComments is released under The MIT License.
- 参考:新时代百科
目录 |
安装
- 下载 ArticleComments, and be sure to rename the downloaded file to ArticleComments.php.
- 保存到 $IP/extensions
- 注意: $IP 是指你的mediawiki安装目录.
- 修改 LocalSettings.php加上:
require_once('extensions/ArticleComments.php');
用法
安装之后, 在你 (或在你编辑任意页面时) 可以添加任意的评论页面到任意一篇文章中.
只需在文章中加入如下代码作为标签:
<comments />
That's it!
技术细节
In addition to providing a parser hook for the <comments> tag, the ArticleComments Extension implements a SpecialPage which acts as the recipient of the submitted comment.
Though this special page shows up in Special:Specialpages as "Process Comment", it is not meant to be accessed directly - only via a comment submission form.
When a comment is submitted, if all fields are correctly filled, with no illegal values, the comment is appended to the end of the Article's Talk page. If the comment form is itself on a Talk page, then the comment is appended to the end of that same page. (Comments are always appended to Talk pages - never pages in any other namespace).
特点
As of version 0.4, this extension registers its own hook called "ArticleCommentsSpamCheck" and provides a default rudimentary implementation.
This is to aid future development of more robust spam checking mechanisms without altering the extension's core code.
Caveats and Gotchas
This extension does not implement any permission checks other than whether the user or ip address is blocked from making edits. This means that if a comment form is placed on an article, any user or guest my use that form to supply a comment.
The goal of this extension is to provide comment forms that are intuitive for people who are not wiki experts, not just to make it easier to append content to an article's talk page. It is presumed that if an editor places a <comments /> flag in an article, then that article is designated as accepting input from any users.
A future version of this extension may be more permissions-aware however.
Related Works
For those of you brave enough to try (and extend/augment) this extension, feel free to list your works below. --Jimbojw
类似 CSS 的讨论页
- 说明
- Article which shows alternate CSS for a more forum-like appearance. Also illustrates some basic configuration options.
- 文档
- How to add comment guestbook forum to mediawiki (LeerWiki.nl)


