ckeditor

Struts 2 - Intercept an image file uploading with CKEditor

余生颓废 提交于 2019-12-07 12:48:09
问题 I have a CKEditor on different pages of the site, so I settled up the uploads to true and all the configuration stuff for it to work, and the image upload worked just fine for "Send it to the Server" tab. But from here I want to intercept or interact with upload function to be able to upload images not to a folder, but into database with some flags like "page" where is image uploaded, "category" , "cropping" and some another manipulations with them. So how could it be done to intercept this

How to integrate CKFinder with Laravel?

大憨熊 提交于 2019-12-07 11:12:47
问题 I'm trying to integrate CKFinder with Laravel, and I'm about 95% there. I can get everything to work, except for the CheckAuthentication function - I have to make it return true regardless for the upload to work. What I've tried doing is bootstrapping Laravel in the config.php file and then checking if a user is logged in, like below: public/packages/ckfinder/config.php <?php /* * ### CKFinder : Configuration File - Basic Instructions * * In a generic usage case, the following tasks must be

CkEditor - Template loaded from AJAX

谁说胖子不能爱 提交于 2019-12-07 10:33:14
问题 I am using CkEditor and would like to define a custom template, that uses an AJAX function to load a HTML string. I have been able to define custom templates, but if I use a function for the html property of the template object the function is never exectuted. Is it possible to load a template using AJAX with the default template plugin or do I need to write my own? config.js CKEDITOR.editorConfig = function (config) { config.templates_files = ['/pathtomyfile/custom.js']; }; custom.js

Add hindi font in CK editor

扶醉桌前 提交于 2019-12-07 08:27:03
问题 I want to add hindi fonts in ck editor. I added following css in content.css of ckeditor. font-family: 'kruti_dev_010regular'; src: url('fonts/kruti_dev_010-webfont.eot'); src: url('fonts/kruti_dev_010-webfont.eot?#iefix') format('embedded-opentype'), url('fonts/kruti_dev_010-webfont.woff2') format('woff2'), url('fonts/kruti_dev_010-webfont.woff') format('woff'), url('fonts/kruti_dev_010-webfont.ttf') format('truetype'), url('fonts/kruti_dev_010-webfont.svg#kruti_dev_010regular') format('svg'

How to show uploading progress in CKEditor?

大城市里の小女人 提交于 2019-12-07 08:23:30
I'm adding a plugin that allow user to upload and display video to CKEditor. The file's size may be big so I'd like to display the upload progress. Currently I'm using the default FileBrowser API to show the upload button, but the document doesn't mention about showing the progress. How can I achieve this? Or do I need to write my own upload plugin? You can trigger the event emitter to check if the upload is in progress a sample code for s3 upload using nodejs function s3uploads(filePath, callback){ var localFile = filePath; var onlyFileName = localFile.split("/"); var fname = (onlyFileName

TinyMCE/CKeditor freezing container div's scrolling when initializing

大兔子大兔子 提交于 2019-12-07 08:08:50
问题 I have TinyMCE initializing textareas that have been loaded via AJAX callback, in a colorbox modal window containing jQuery UI tabs panels. The panel that the textareas are being loaded into are scrollable (overflow-y:auto). However, it seems that when I initialize TinyMCE on these new textareas, it scrolls about halfway down to one of the lower textareas on the list, and initializes them correctly, but you can no longer scroll the container panel's div in Chrome. You can still scroll the

Getting CKEditor to work with Flask Admin

岁酱吖の 提交于 2019-12-07 03:44:28
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 import Flask from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.login import LoginManager from

How to destroy inline CKEditor with jQuery

試著忘記壹切 提交于 2019-12-07 02:37:22
问题 Let's say that this is code I have: <div class="editor" contenteditable></div> // This is working for me $('.editor').click(function(){ $(this).ckeditor(); }); // This is the problem $('.editor').on('focusout', function(){ $(this).ckeditorDestroy(); // What will destroy ckeditor? }); I know that this function doesn't exists, but I didn't found nothing what was working? 回答1: HTML <div contenteditable="true" class="editor">Editor 1!</div> <div contenteditable="true" class="editor">Editor 2!<

Detect focus of CKEditor

送分小仙女□ 提交于 2019-12-07 02:28:39
问题 trying to fix the issue where on an IOS device the keyboard disrupts fixed elements. When clicking on a CKEditor text area, my aim is to set the style of that fixed element back to fixed. Not sure how to detect the CKEditor being focused however. Nothing I have tried has worked, here is the basic though: http://jsfiddle.net/B4yGJ/180/ CKEDITOR.replace('editor1'); $('#editor1').focus(function() { alert('Focused'); }); 回答1: CKEditor has a custom focus event, that will be useful to you. See the

bootstrapvalidator gives “Cannot read property 'group' of undefined” on ckeditor field

佐手、 提交于 2019-12-07 00:45:30
I'm using ckeditor on a text area and I need to set a custom validation. Following the example, I set the textbox using the jquery adapter in this way: $('#posteditor') .bootstrapValidator() .find('[name="text"]').ckeditor({ skin: 'moono,/asset/css/moono/', language: 'it', toolbarGroups: [ {"name":"basicstyles","groups":["basicstyles"]}, {"name":"paragraph","groups":["list","align"]}, {"name":"insert","groups":["insert"]}, {"name":"styles","groups":["styles"]}, {"name":"links","groups":["links"]}, ], removeButtons: 'Strike,SpecialChar,Anchor', extraPlugins: 'youtube' }).editor.on('change',