Extension:MsInsert/ja

Category:GPL licensed extensions/ja
MediaWiki 拡張機能マニュアル
MsInsert
リリースの状態: 安定Category:Stable extensions/ja
実装 ユーザー インターフェイスCategory:User interface extensions/ja
説明 Adds a dropdown menu for inserting into the editor the content of certain pages
作者 Martin Schwindl, Martin Keyler
メンテナー Sophivorus
最新バージョン 4.0 (2024-06-17)
MediaWiki 1.39+Category:Extensions with manual MediaWiki version
PHP 8.2+
ライセンス GNU 一般公衆利用許諾書 2.0 以降
ダウンロード Category:Extensions in Wikimedia version control/ja
  • $wgTemplates
四半期ごとのダウンロード数 4 (Ranked 90th)
translatewiki.net で翻訳を利用できる場合は、MsInsert 拡張機能の翻訳にご協力ください
Category:All extensions/ja

The MsInsert extension adds a dropdown menu to the editor (both the WikiEditor and the regular editor) that allows you to insert into the wikitext the content of any wiki page listed in the dropdown menu.

The wiki pages are added to the dropdown menu from LocalSettings.php.

インストール

  • ダウンロードして、ファイルをextensions/フォルダー内のMsInsertという名前のディレクトリ内に配置します。
    開発者とコード寄稿者は、上記の代わりに以下を使用してGitからインストールします:cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/MsInsert
  • 以下のコードを LocalSettings.php ファイルの末尾に追加します:
    wfLoadExtension( 'MsInsert' );
    
  • Yes 完了 – ウィキの「Special:Version」に移動して、拡張機能が正しくインストールされたことを確認します。

設定

To add a page to the dropdown menu, add it to the $wgTemplates array in your LocalSettings.php, like so:

$wgTemplates = [ 'Template:Test', 'Main Page', 'Talk:Main Page' ];

Or alternatively:

$wgTemplates[] = 'Template:Test';
$wgTemplates[] = 'Main Page';
$wgTemplates[] = 'Talk:Main Page';

If the page does not exist yet, then it will not be added to the dropdown menu, even if it's listed in the $wgTemplates array. By default, the array is empty.

使用法

Once a page has been added to the $wgTemplates, it will appear listed in the dropdown menu whenever you edit a page. By selecting it in the dropdown menu, the extension will fetch its contents and insert them into the wikitext, wherever you had the cursor.

関連項目

Category:All extensions/ja Category:EditPage::showEditForm:initial extensions/ja Category:Extensions in Wikimedia version control/ja Category:Extensions with manual MediaWiki version Category:GPL licensed extensions/ja Category:ResourceLoaderGetConfigVars extensions/ja Category:Stable extensions/ja Category:User interface extensions/ja