FIX #2056: areYouSure now reacts also on changes in CKEditor
This commit is contained in:
@@ -10,7 +10,7 @@
|
|||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
<form method="POST" enctype="multipart/form-data" action="{{route('content.newPost', ['moduleId' => $module->id])}}">
|
<form method="POST" enctype="multipart/form-data" action="{{route('content.newPost', ['module' => $module])}}">
|
||||||
{!! csrf_field() !!}
|
{!! csrf_field() !!}
|
||||||
|
|
||||||
@include('admin.content.formInputs')
|
@include('admin.content.formInputs')
|
||||||
|
|||||||
@@ -1,29 +1,37 @@
|
|||||||
<script src="{{asset('/resources/assets/js/vendor/ckeditor/ckeditor.js')}}"></script>
|
<script src="{{asset('/resources/assets/js/vendor/ckeditor/ckeditor.js')}}"></script>
|
||||||
|
|
||||||
<script type="application/javascript">
|
<script type="application/javascript">
|
||||||
CKEDITOR.replace ('{{$textareaId}}', {
|
CKEDITOR.on('instanceCreated', function(e) {
|
||||||
uiColor: "#F5F5F5",
|
e.editor.on('change', function(event) {
|
||||||
filebrowserUploadUrl: '{{route('upload.postFile', ['_token' => csrf_token()])}}',
|
var textarea = event.editor.element.$;
|
||||||
forcePasteAsPlainText: true,
|
$(textarea).val(event.editor.getData().trim());
|
||||||
entities: false,
|
$(textarea.form).trigger('checkform.areYouSure');
|
||||||
basicEntities: false,
|
});
|
||||||
entities_greek: false,
|
})
|
||||||
entities_latin: false,
|
|
||||||
height: 550,
|
CKEDITOR.replace ('{{$textareaId}}', {
|
||||||
removePlugins: 'about,scayt', //elementspath
|
uiColor: "#F5F5F5",
|
||||||
extraPlugins: 'justify',
|
filebrowserUploadUrl: '{{route('upload.postFile', ['_token' => csrf_token()])}}',
|
||||||
enterMode: CKEDITOR.ENTER_P,
|
forcePasteAsPlainText: true,
|
||||||
toolbarGroups: [
|
entities: false,
|
||||||
{name: 'undo', groups: ['undo']},
|
basicEntities: false,
|
||||||
{name: 'styles'},
|
entities_greek: false,
|
||||||
{name: 'basicstyles', groups: ['basicstyles', 'cleanup']},
|
entities_latin: false,
|
||||||
{name: 'paragraph', groups: ['list', 'indent', 'align', 'blocks']},
|
height: 550,
|
||||||
{name: 'links'},
|
removePlugins: 'about,scayt', //elementspath
|
||||||
{name: 'editing', groups: ['find', 'selection']},
|
extraPlugins: 'justify',
|
||||||
{name: 'insert'},
|
enterMode: CKEDITOR.ENTER_P,
|
||||||
{name: 'forms'},
|
toolbarGroups: [
|
||||||
{name: 'document', groups: ['mode', 'document', 'doctools']},
|
{name: 'undo', groups: ['undo']},
|
||||||
{name: 'tools'}
|
{name: 'styles'},
|
||||||
]
|
{name: 'basicstyles', groups: ['basicstyles', 'cleanup']},
|
||||||
});
|
{name: 'paragraph', groups: ['list', 'indent', 'align', 'blocks']},
|
||||||
|
{name: 'links'},
|
||||||
|
{name: 'editing', groups: ['find', 'selection']},
|
||||||
|
{name: 'insert'},
|
||||||
|
{name: 'forms'},
|
||||||
|
{name: 'document', groups: ['mode', 'document', 'doctools']},
|
||||||
|
{name: 'tools'}
|
||||||
|
]
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
Reference in New Issue
Block a user