redactor2
4.2.1
redactorEditor2-%profileName%
クラスのテキストエリアは、通常のテキスト入力フィールドから WYSIWYG エディターに自動的に変換されます。 B. <textarea class="redactorEditor2-full"></textarea>
、yForm テキスト領域の「個別属性」フィールド: {"class":"redactorEditor2-full"}
Redactor エディターの異なる構成設定を持つ異なるプロファイルをバックエンドで作成できます。
エディターに独自の CSS スタイルを与えるオプションがあります。必要なのは、 skin.css
というファイルを/assets/addons/ redactor2
フォルダーに作成することだけです。
モジュール入力:
< fieldset class =" form-horizontal " >
< div class =" form-group " >
< label class =" col-sm-2 control-label " for =" value-1 " > VALUE 1 </ label >
< div class =" col-sm-10 " >
< textarea class =" form-control redactorEditor2-full " id =" value-1 " name =" REX_INPUT_VALUE[1] " > REX_VALUE[1] </ textarea >
</ div >
</ div >
</ fieldset >
モジュール出力:
REX_VALUE [id= " 1 " output= " html " ]
モジュールまたはアドオンを使用してプロファイルを作成します。
<?php
if (! redactor2 :: profileExists ( ' simple ' )) {
redactor2 :: insertProfile ( ' simple ' , $ description = '' , $ minheight = ' 300 ' , $ maxheight = ' 800 ' , $ urltype = ' relative ' , $ characterlimit = 0 , $ toolbarfixed = 0 , $ shortcuts = 0 , $ linkify = 1 , $ redactorPlugins = '' );
}
?>