Extension:ClipBox
Appearance
リリースの状態: 安定 |
|
|---|---|
| 実装 | タグ |
| 説明 | embed inputbox to copy text for clipboard e.g. campaign code |
| 作者 | Kimagurenote (Coryトーク) |
| 最新バージョン | 1.0.0 |
| MediaWiki | 1.25+ |
| データベースの変更 | いいえ |
<clipbox> |
|
| ライセンス | 「修正」三条項 BSD ライセンス |
| ダウンロード | Download History |
| 例 | kimagurenote.net |
The ClipBox extension provides a way to embed inputbox to copy text for clipboard e.g. campaign code.
インストール
- Download zip file from author's website, unzip itして、ファイルを
extensions/フォルダー内のClipBoxという名前のディレクトリ内に配置します。 - 以下のコードを LocalSettings.php ファイルの末尾に追加します:
/* Extension:ClipBox */ wfLoadExtension( 'ClipBox' );
- Add the following code at the bottom of your
MediaWiki:Common.css. You can fully customize it.
/* Extension:ClipBox */
.clipbox {
font-size: 16px;
color: #333;
align-items: center;
}
.clipbox input {
padding: 7px 0;
text-align: center;
border-radius: 5px;
font-size:14px;
letter-spacing:1px;
}
.clipbox button {
font-size: 16px;
padding: 9px;
border-radius: 5px;
color:#444;
}
.clipbox button:hover {
opacity: 0.8;
}
完了 – ウィキの「Special:Version」に移動して、拡張機能が正しくインストールされたことを確認します。
You will need interface-admin permission to edit Common.css on MediaWiki 1.32 or above.
使用法
embed simply
Just embed an inputbox and button simply. 例:
<clipbox>MYCODE</clipbox>
パラメーター
You can specify some parameters. 例:
<clipbox
id="mycampaign"
size="15"
title="My campaign code"
input="readonly"
style="text-align: center;">
MYCODE
</clipbox>
ID and size are applied <input> directly.
style and title are applied <div> directly.
And you can specify input="readonly" for suppress to edit inputbox by user.
If you use two or more <clipbox> tags in same page, you must set different id on all tags.
Notes
This extension will not work on browsers disabled JavaScript.
See also
- ClipBox (author site, written in Japanese)
- Extension:PreToClip
