本文整理汇总了PHP中dosamigos\ckeditor\CKEditor::init方法的典型用法代码示例。如果您正苦于以下问题:PHP CKEditor::init方法的具体用法?PHP CKEditor::init怎么用?PHP CKEditor::init使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类dosamigos\ckeditor\CKEditor
的用法示例。
在下文中一共展示了CKEditor::init方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: init
public function init()
{
$theme = new AppAsset();
$baseUrl = \Yii::getAlias($theme->baseUrl);
$cssList = [];
foreach ($theme->css as $css) {
if (preg_match('#^http#', $css)) {
continue;
}
$cssList[] = $baseUrl . '/' . $css;
}
$this->clientOptions = ['toolbar' => 'full', 'contentsCss' => $cssList, 'allowedContent' => true, 'disallowedContent' => 'img{width,height,style}', 'extraAllowedContent' => 'div(*){*}[*],span(*){*}[*]', 'shiftEnterMode' => 2, 'image2_disableResizer' => true, 'image2_prefillDimensions' => false];
if ($this->userOptions) {
foreach ($this->userOptions as $k => $v) {
$this->clientOptions[$k] = $v;
}
}
parent::init();
}
示例2: init
public function init()
{
$this->clientOptions = \mihaildev\elfinder\ElFinder::ckeditorOptions('elfinder', []);
parent::init();
}