2
我是Yii框架的新手, 我需要一个FCK编辑器来管理我的CMS管理页面。我下载并提取了FCKeditor到yii扩展文件夹中的根文件夹及其扩展名。并在我看来添加了以下代码如何在Yii中设置FCK编辑器?
<?php $this->widget('application.extensions.fckeditor.FCKEditorWidget',array(
"model"=>$model, # Data-Model
"attribute"=>'content', # Attribute in the Data-Model
"height"=>'400px',
"width"=>'100%',
"toolbarSet"=>'Basic', # EXISTING(!) Toolbar (see: fckeditor.js)
"fckeditor"=>Yii::app()->basePath."/../fckeditor/fckeditor.php",
# Path to fckeditor.php
"fckBasePath"=>Yii::app()->baseUrl."/fckeditor/",
# Realtive Path to the Editor (from Web-Root)
"config" => array(
"EditorAreaCSS"=>Yii::app()->baseUrl.'/css/index.css',),
# http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options
# Additional Parameter (Can't configure a Toolbar dynamicly)
)); ?>
这些都工作正常。 但编辑器是分开显示的。我需要编辑器代替内容textarea。
每次我看到FCK编辑器我认为它说别的... – goat