ckeditor

ckeditor + jquery + fancybox

£可爱£侵袭症+ 提交于 2019-12-13 21:02:02
问题 Purpose is to have a small icon on my admin page. Clicking this icon will fire a modal window with an instance of ckeditor textarea. The user edit the text, saves it and modal closes. My problem is that if i click again on the icon, the new editor instance is empty. Below you can see the relevant codes HTML Part: <a id="editShortText" title="Short Description" href="#saveShortTextFrm"><img src="clickme.gif"> <div style="display:none"> <form action="" method="post" id="saveShortTextFrm" name=

CKEditor5 use model in custom Data Processor

好久不见. 提交于 2019-12-13 20:27:50
问题 I was playing with CKEDitor5, and I tried to create a custom Data Processor. I'd like to use the model in the toData conversion, but the method is called with the view/DocumentFragment object. So my question is that how could I convert that into a model/DocumentFragment object (or how to access the model from a data processor). Update (as it cannot fit into a comment): Let me try to better explain what exactly I try to do (or I already did so far) in a bit more detail. I figured out how to

Ckeditor inline editor stays on screen when scrolling a “scrollable” div

谁说胖子不能爱 提交于 2019-12-13 18:30:36
问题 I have a "scrollable" div. Inside this div i have some text and another div with contenteditable=true. The HTML source looks like this <div id='scrollable' style="overflow:scroll;height:500px;width:90%;position:absolute"> some text <div id='editable' style="color:red" contenteditable=true>editable div</div> some text </div> An inline ckeditor editor for the "editable" div should appear on page load. This is done by focusing the div. $( document ).ready(function() { $("#editable").focus(); });

How can I add rel = “nofollow” to a link in CKEditor if it's an external link

梦想的初衷 提交于 2019-12-13 17:13:21
问题 i want to give rel="nofollow" to my external links which its content managed by ckeditor. example.com = my site externallink.com = any external link For example: <p> Lorem <a href="https://example.com/an-article.html">ipsum</a> dolar <a href="http://externallink.com/example.html" rel="nofollow">sit</a> amet. </p> This solution: editor.dataProcessor.htmlFilter.addRules( { elements : { a : function( element ) { if ( !element.attributes.rel ) element.attributes.rel = 'nofollow'; } } }); from

How to fix error Cannot find name 'object' in angular 2 cli ckeditor

懵懂的女人 提交于 2019-12-13 16:14:12
问题 I have insalled ng2-ckeditor using cli : npm install ng2-ckeditor --save Then Include CKEditor javascript files in my index file : <script src="https://cdn.ckeditor.com/4.5.11/full/ckeditor.js"></script> Then imported module in module file: import { CKEditorModule } from 'ng2-ckeditor'; in imports "CKEditorModule" and trying to use in html It show error: ERROR in /var/www/html/eventswebsite/frontendapp/node_modules/ng2-ckeditor/lib/ckeditor.component.d.ts (43,26): Cannot find name 'object'.

CKEditor: Remove 'Link Type' option, but set URL as default Link Type?

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-13 16:11:43
问题 I'm using the Link plugin for CKEditor, and I'm trying to remove the 'Link Type' option so a user can input an address into the URL field and not have to set the 'Link Type' option. When I use the code below, it removes the 'Link Type' option, but when you try to click the link it creates, it doesn't open the link as intended. So I'm wondering how can I set the default 'Link Type' as a URL so the link can be opened successfully, but also remove the option to set 'Link Type' manually? CKEDITOR

CKEditor keyup event and capturing data from inline editors

独自空忆成欢 提交于 2019-12-13 15:22:31
问题 I'm trying to create a document with multiple inline CKEditor fields, and keyup is throwing me for a loop. The "key" event works fine(but doesn't get the last character entered), however "keyups" aren't caught at all, unless I use the editor.document.on, which is what several other answers happily provided. Unfortunately, since I have multiple(over 13) possible fields, the event seems to not return anything with it other than just the event itself. No target information(I need the ID to pass

How to add the audio tag in the CKeditor

末鹿安然 提交于 2019-12-13 14:57:24
问题 I have added the html5audio plugin and able to get the Upload button , but how to send the uploaded file to the server. Here is my plugin Code { id: 'Upload', hidden: false, filebrowser: 'uploadButton', label: editor.lang.html5audio.upload, elements: [ { type: 'file', id: 'upload', label: editor.lang.html5audio.btnUpload, style: 'height:40px', size: 38 }, { type: 'fileButton', id: 'uploadButton', filebrowser: 'info:url', label: editor.lang.html5audio.btnUpload, 'for': [ 'Upload', 'upload' ] }

ckeditor jquery plugin and the blur event

北城以北 提交于 2019-12-13 14:34:39
问题 I'm currently working with ckeditor and i'm using the jquery plugin for this editor for instantiating everything when the document is ready. What I need to do is setup a blur event for the instance of ckeditor that is being created. The below code is what I'm using to instantiate ckeditor. $("textarea.editor").ckeditor(); What I'm trying to do is something like: $("textarea.editor").blur(); Is there a way to do this with ckeditor using the jquery plugin for it? 回答1: You need to bind your

Disable ckeditor context menu in version 4.4.6

故事扮演 提交于 2019-12-13 12:28:43
问题 I am using ckeditor in a Rails4 project. I have tried both the ckeditor gem and the ckeditor_rails gem to provide the ckeditor libraries. There are multiple posts here by people wanting to remove the ckeditor context menu so that the native browser context menu can be displayed. This is usually to enable the browser spellchecker to be used rather than the ckeditor paid / advertised spellchecker. how-to-remove-contextmenu-in-ckeditor-4-3 ckeditor-3-6-3-enable-browser-spellcheck-and-disable