Help:Extension/Secret
From Metabolomics.JP
(Difference between revisions)
Line 2: | Line 2: | ||
|author=K, Suwa | |author=K, Suwa | ||
|version=0.1 | |version=0.1 | ||
+ | |type=other | ||
}} | }} | ||
Latest revision as of 14:21, 1 March 2011
Extension Information | |
Implementation | |
Description | |
Author(s) | K, Suwa |
Version | 0.1 |
MediaWiki | |
License | |
Hooks used | |
Token type | other |
Contents |
mediawikiは細かな権限設定を行うことができません。また、権限はユーザ単位ではなくグループ単位でのみ設定可能です。
Secretはユーザ単位、アクション毎、名前空間毎に権限を設定できます。例えば、ある名前空間は'WikiSysop'のみ閲覧可能にするなどです。
このextensionはuserCanというフックを利用しています。
[edit] Example
Secret.phpの"/* Please write permission settings here"以下に次の2行を追加して下さい。
if( $ns == NS_SPECIAL ) $result = false;
この設定により、全ユーザは特別ページにアクセスできなくなります。
※チェックが終わったら、この設定は削除して下さい。
[edit] Requirements
None
[edit] Download
version | source | md5 | OperationCheck version |
0.1(December 9,2009) | Secret.phps | c45d54c9ddff0a9f10964b4b3d1e6562 | 1.11.1, 1.16.2 |
[edit] Installtion
- Download the source code and rename it to Secret.php.
- Place it in the extensions/ directory.
- Insert the follow lines to LocalSettings.php
require_once( "$IP/extensions/Secret.php" );
- Secret.php内のisSecretPage関数に必要な処理を記述して下さい。