ckeditor

CK editor find and replace will works only first time then it will gives index error in ranges[0].setStart function

为君一笑 提交于 2019-12-23 02:39:33
问题 CK editor find and replace will work only first time then it always gives index error in ranges[0].setStart function. I have tried with editor.updateElement(); but it's not working. function test() { try { var editor = CKEDITOR.instances[("<%=ckDescription.ClientID %>")]; var sel = editor.getSelection(); var element = sel.getStartElement(); sel.selectElement(element); var findString = 'FE'; var ranges = editor.getSelection().getRanges(); var startIndex = element.getText().indexOf(findString);

Ruby on Rails: problem getting CKeditor to upload images

橙三吉。 提交于 2019-12-23 01:43:51
问题 When I pick a file and click "Send it to the Server" I get the error: ActionController::InvalidAuthenticityToken in MediasController#new_from_disk Parameters: {"upload"=>#<File:/var/folders/Fr/FrWbhcV1HdGpFgn7Lh7OhU+++TI/-Tmp-/RackMultipart20100802-4884-olu0e5-0>, "CKEditorFuncNum"=>"42", "langCode"=>"en", "CKEditor"=>"object_content_body"} from my understanding, the ckeditor uploader sends my ruby action the file, and I handle it then and there. So I don't need a view associated with my new

Getting CKEditor to work with Flask Admin

放肆的年华 提交于 2019-12-23 01:40:11
问题 I'm trying to make turn the Flask Admin text box into a CKEdit box, as described here. However, when I run it and go to the existing admin fields it doesn't show any change to the text boxes, and when I run it and go to the TestAdmin field created to demonstrate I get this error: OperationalError: (OperationalError) no such table: test u'SELECT count(?) AS count_1 \nFROM test' ('*',) Along with a bunch of other traceback messages. I have changed my init script to be this: import os from flask

CKEditor: call a plugin function without toolbar button

纵饮孤独 提交于 2019-12-23 01:36:32
问题 How can I call a plugin function without a toolbar button? I have an external floating toolbar integrated in my cms. I insert images, videos and other pieces of static code with the InsertHTML() API of CKEditor. Now I need to insert also video from URL, and there is the fantastic oembed plugin. How can I fire that plugin using a button in my cms without the toolbar button? I load the plugin in my config, and I try to create this function: function oembed() { // Get the editor instance that we

CKEditor: call a plugin function without toolbar button

柔情痞子 提交于 2019-12-23 01:36:06
问题 How can I call a plugin function without a toolbar button? I have an external floating toolbar integrated in my cms. I insert images, videos and other pieces of static code with the InsertHTML() API of CKEditor. Now I need to insert also video from URL, and there is the fantastic oembed plugin. How can I fire that plugin using a button in my cms without the toolbar button? I load the plugin in my config, and I try to create this function: function oembed() { // Get the editor instance that we

Multiple instances of CKEditor (in Safari) [duplicate]

时光毁灭记忆、已成空白 提交于 2019-12-22 17:55:57
问题 This question already has answers here : CKEditor instance already exists (32 answers) Closed 6 years ago . I'm having a problem creating multiple instances of a CKEditor in a JQuery UI dialog. The dialog loads a remote form via AJAX, so the goal is to be able to close and reopen the dialog and have a new instance of the editor. With the default options, when reopening the dialog it gives an error saying that an editor with that name already exists. So I have tried several methods of

How to change the default browse directory for images in KCFinder?

无人久伴 提交于 2019-12-22 14:55:16
问题 I'm using CKEditor with KCFinder. Everything works great except one thing. My default upload URL is: 'uploadURL' => "/userfiles" Let's say I want to upload an image. I click on Upload image in CKEditor, then I click on Browse the Server to select one already uploaded. Problem is that CKEditor is browsing /userfiles/images instead of just /userfiles like I would like to. I understand that this is not a bug and just a way it was set up but how do I change it? I didn't find anything on http:/

How to change the default browse directory for images in KCFinder?

泪湿孤枕 提交于 2019-12-22 14:55:04
问题 I'm using CKEditor with KCFinder. Everything works great except one thing. My default upload URL is: 'uploadURL' => "/userfiles" Let's say I want to upload an image. I click on Upload image in CKEditor, then I click on Browse the Server to select one already uploaded. Problem is that CKEditor is browsing /userfiles/images instead of just /userfiles like I would like to. I understand that this is not a bug and just a way it was set up but how do I change it? I didn't find anything on http:/

How to set CKEditor 5 height

大憨熊 提交于 2019-12-22 11:27:09
问题 Using CKeditor angular component How to set the editor height? According to the docs, it can be done by setting the editor style to: min-height: 500px !important; But it doesn't work! 回答1: If you add it to the global stylesheet the following should work: .ck-editor__editable_inline { min-height: 500px !important; } But if you want to style through the component.css you need to type this: :host ::ng-deep .ck-editor__editable_inline { min-height: 500px !important; } 来源: https://stackoverflow

CKEDITOR: how to I convert ALL html entities

。_饼干妹妹 提交于 2019-12-22 11:08:34
问题 here is the list: http://www.elizabethcastro.com/html/extras/entities.html I either want to enable all of them, or disable all of them... (aside from < and > of course) Is there a way to do this? there is the config.entities_additional = "", but that is a comma separated list of all the entities you want to store. preferably, I'd like to disable the entities entirely, but setting config.entities = false; doesn't do anything. o.o @Cheery's answer solves the situation where the editor uses the