Help:Extension/Volatile

From Metabolomics.JP
(Difference between revisions)
Jump to: navigation, search
 
(14 intermediate revisions by one user not shown)
Line 1: Line 1:
 
{{Extension
 
{{Extension
 
|author=K, Suwa
 
|author=K, Suwa
|version=0.1
+
|version=0.12
|mediawiki=1.11.1
+
|type=Link markup
 
}}
 
}}
  
 
__TOC__
 
__TOC__
  
Volatile機能は、VolatileリンクとVolatile名前空間の二つで構成されます。
+
Volatile is achieved by Volatile link and Volatile namespace.  See also [[Help:Extension/Persistency|Persistency]].
  
 +
;Volatile link : <nowiki>[[Volatile:page?param1&param2&...&paramN|name]]</nowiki> specifies a page in Volatile namespace and its parameters.  In the specified page, the contents are expanded with the parameters (without cash). 
  
Volatileリンクは<nowiki>[[Volatile:~]]</nowiki>で作ることができ、飛ばすVolatile名前空間のページと引数を指定します。
+
;Volatile namespace : The notation of page contents is the same as Template namespace.  Use {{{1}}}, {{{2}}} ... for parameters.
  
Volatile名前空間のページには、Template名前空間と同じような{{{1}}}や{{{ID}}}を記述します。
+
== Example ==
 +
一つ目の引数に「first_arg」、二つ目の引数に「second_arg」と言う文字列を渡すVolatileの使い方です。
  
Volatileリンクより飛ばされたVolatile名前空間のページでは、引数が{{{~}}}に割り当てられ表示されます。
+
* ソース
 +
<nowiki>[[Volatile:Help:Extension/Volatile?my_1=first_arg&my_2=second_arg|volatile test]]</nowiki>
  
 +
* テンプレートソース
 +
** Volatile:Help:Extension/Volatile <pre>一つ目の引数{{{1}}}、二つ目の引数{{{2}}}</pre>
  
Template機能と似ていますが、Template機能はTemplateを別のページから呼び出すのに対し、Volatile機能は引数を持ってTemplateに飛び込むイメージです。
+
* 実行例
 
+
[[Volatile:Help:Extension/Volatile?my_1=first_arg&my_2=second_arg|volatile test]]
また、Volatileリンクによりアクセスされたページはキャッシュされることなく、Volatileリンクの引数を変える(もしくは、別のVolatileリンクを用意する)ことで、一つのページだけで動的に情報を変えることができます。
+
  
 
== Requirements ==
 
== Requirements ==
[[Doc:Extension/HTMLForm|HTMLForm]]
+
* [[Doc:Extension/HTMLForm|HTMLForm]]
  
 
== Download ==
 
== Download ==
 
<table border="1" cellpadding="3" cellspacing="1">
 
<table border="1" cellpadding="3" cellspacing="1">
  <tr><td>version</td><td>source</td><td>size</td></tr>
+
  <tr><td>version</td><td>source</td><td>md5</td><td>OperationCheck version</td></tr>
  <tr><td>0.1(September 11,2008)</td><td>Volatile.phps</td><td></td></tr>
+
  <tr><td>0.12(March 21,2009)</td><td>{{#ifexistfile:/data/src/Volatile/Volatile.phps}}</td><td><pre style="border: 0px; background-color: white; padding: 0em; line-height: 0em">1ec87da5d0c6c627f8a1f086b493e7db</pre></td><td>1.11.1, 1.16.2</td></tr>
 +
<tr><td>0.11(October 23,2008)</td><td>{{#ifexistfile:/data/src/Volatile/previous/Volatile-0.11.phps}}</td><td><pre style="border: 0px; background-color: white; padding: 0em; line-height: 0em">46e6021b00cfdb21ffc677d5dc61d455</pre></td><td>1.11.1</td></tr>
 
</table>
 
</table>
  
 
== Installtion ==
 
== Installtion ==
 
<ol>
 
<ol>
  <li>Download source and rename to Volatile.php.</li>
+
  <li>Download the source code and rename it to Volatile.php.</li>
  <li>Put in extensions/ directory.</li>
+
  <li>Place it in the extensions/ directory.</li>
  <li>Insert follow line to LocalSettings.php
+
  <li>Insert the follow lines to LocalSettings.php
 
   <pre>require_once( "$IP/extensions/Volatile.php" );
 
   <pre>require_once( "$IP/extensions/Volatile.php" );
 
$wgExtraNamespaces = array( ...
 
$wgExtraNamespaces = array( ...
Line 40: Line 45:
 
   ...
 
   ...
 
);
 
);
</pre>xxxは既に存在する名前空間番号と競合しない100番以降の番号を指定して下さい。</li>
+
</pre>
 +
Use 100 or larger numbers for xxx. </li>
 
</ol>
 
</ol>
  
 
== Function ==
 
== Function ==
# [[Doc:Extensions#Volatile_page_.5B.5BVolatile:pagename.7Carg1.7Carg2.7C....7Clinkname.5D.5D|volatile]]
+
# [[Help:Extensions#Volatile_page_.5B.5BVolatile:pagename.7Carg1.7Carg2.7C....7Clinkname.5D.5D|volatile]]
 +
 
 +
== ChangeLog ==
 +
0.12
 +
* Volatileの$を含む引数がphpの変数として解釈されてしまうバグを修正

Latest revision as of 14:11, 1 March 2011

Extension Information
Implementation
Description
Author(s)K, Suwa
Version0.12
MediaWiki
License
Hooks used
Token typeLink markup

Contents


Volatile is achieved by Volatile link and Volatile namespace. See also Persistency.

Volatile link 
[[Volatile:page?param1&param2&...&paramN|name]] specifies a page in Volatile namespace and its parameters. In the specified page, the contents are expanded with the parameters (without cash).
Volatile namespace 
The notation of page contents is the same as Template namespace. Use {{{1}}}, {{{2}}} ... for parameters.

[edit] Example

一つ目の引数に「first_arg」、二つ目の引数に「second_arg」と言う文字列を渡すVolatileの使い方です。

  • ソース
[[Volatile:Help:Extension/Volatile?my_1=first_arg&my_2=second_arg|volatile test]]
  • テンプレートソース
    • Volatile:Help:Extension/Volatile
      一つ目の引数{{{1}}}、二つ目の引数{{{2}}}
  • 実行例

volatile test

[edit] Requirements

[edit] Download

versionsourcemd5OperationCheck version
0.12(March 21,2009)Volatile.phps
1ec87da5d0c6c627f8a1f086b493e7db
1.11.1, 1.16.2
0.11(October 23,2008)Volatile-0.11.phps
46e6021b00cfdb21ffc677d5dc61d455
1.11.1

[edit] Installtion

  1. Download the source code and rename it to Volatile.php.
  2. Place it in the extensions/ directory.
  3. Insert the follow lines to LocalSettings.php
    require_once( "$IP/extensions/Volatile.php" );
    $wgExtraNamespaces = array( ...
       xxx => "Volatile", xxx+1 => "Volatile_Talk",
       ...
    );
    
    Use 100 or larger numbers for xxx.

[edit] Function

  1. volatile

[edit] ChangeLog

0.12

  • Volatileの$を含む引数がphpの変数として解釈されてしまうバグを修正
Personal tools
Namespaces

Variants
Actions
Navigation
metabolites
Toolbox