我做了一个自定义的ckeditor,但我有所有基本的东西加上一些。我一直在尝试使用ckeditor并尝试通过类名和javascript代码替换textarea元素,但在这两种情况下,我在textarea中得到的只是
我的代码在这里:
{{ Form::textarea('LONG_DESCRIPTION', $article->LONG_DESCRIPTION, ['class' => 'edito', 'id'=>'editor1']) }}
<script src="/*****/vendor/ckeditor/ckeditor.js"></script>
<script>
CKEDITOR.replace('editor1',
{
toolbar: 'MyToolbar'
});
</script>
以下是配置文件:
CKEDITOR.editorConfig = function( config ) {
// Define changes to default configuration here. For example:
// config.language = 'fr';
// config.uiColor = '#AADC6E';
config.toolbar = 'MyToolbar';
config.toolbar_MyToolbar =
[
{ name: 'document', items : [ 'NewPage','Preview' ] },
{ name: 'clipboard', items : [ 'Cut','Copy','Paste','PasteText','PasteFromWord','-','Undo','Redo' ] },
{ name: 'editing', items : [ 'Find','Replace','-','SelectAll','-','Scayt' ] },
{ name: 'insert', items : [ 'Image','Flash','Table','HorizontalRule','Smiley','SpecialChar','PageBreak'
,'Iframe' ] },
'/',
{ name: 'styles', items : [ 'Styles','Format' ] },
{ name: 'basicstyles', items : [ 'Bold','Italic','Strike','-','RemoveFormat' ] },
{ name: 'paragraph', items : [ 'NumberedList','BulletedList','-','Outdent','Indent','-','Blockquote' ] },
{ name: 'links', items : [ 'Link','Unlink','Anchor' ] },
{ name: 'tools', items : [ 'Maximize','-','About' ] }
];
};
我做错了什么或者错误,因为它没有工作,只是在图像中出现?