aloha-editor

Aloha editor: Inserting images/pictures

旧时模样 提交于 2020-01-31 15:13:13
问题 I'm using Aloha editor for editing content on a website powered by PHP and MySQL. It's working fine, but I need to be able to insert images/pictures. I found an Aloha editor plugin for that. Here are some links: http://labs.tapo-it.com/aloha-editor/image-plugin/ http://aloha-editor.org/wiki/ImagePlugin https://github.com/alohaeditor/Aloha-Plugin-Image There is an example in the first link. However, I can't get the plugin running on the latest version of Aloha editor and jQuery. It fails to

Aloha editor: Inserting images/pictures

拜拜、爱过 提交于 2020-01-31 15:10:25
问题 I'm using Aloha editor for editing content on a website powered by PHP and MySQL. It's working fine, but I need to be able to insert images/pictures. I found an Aloha editor plugin for that. Here are some links: http://labs.tapo-it.com/aloha-editor/image-plugin/ http://aloha-editor.org/wiki/ImagePlugin https://github.com/alohaeditor/Aloha-Plugin-Image There is an example in the first link. However, I can't get the plugin running on the latest version of Aloha editor and jQuery. It fails to

Listening to the Aloha Editor “aloha-smart-content-changed” Event?

风流意气都作罢 提交于 2019-12-08 19:53:32
问题 Accoriding to the Aloha Editor docs you can listen for the "aloha-smart-content-changed" event for help in, say, saving the data to whatever persistence mechanism you are using. Here is an example of what I am trying to do: <html> <head> <title>Aloha Event Testing</title> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script> <script src="http://cdn.aloha-editor.org/current/lib/aloha.js" data-aloha-plugins="common/format, common/list, common/link, common

How to disable Aloha Editor toolbar?

纵饮孤独 提交于 2019-12-07 04:04:09
问题 Is there a way to disable Aloha's ExtJS toolbar in the same way as sidebar? Aloha.settings = modules: ['aloha', 'aloha/jquery'] editables: '.editable' jQuery: $ sidebar: disabled: true toolbar: disabled: true # does not work 回答1: Mark element with class <div class="editable notoolbar"></div> Use event: Aloha.ready(function () { var $ = Aloha.jQuery; Aloha.bind('aloha-editable-activated', function () { if ($(Aloha.activeEditable.obj[0]).hasClass("notoolbar")) { $(".aloha-toolbar").hide(); } })

How to disable Aloha Editor toolbar?

橙三吉。 提交于 2019-12-05 07:56:59
Is there a way to disable Aloha's ExtJS toolbar in the same way as sidebar? Aloha.settings = modules: ['aloha', 'aloha/jquery'] editables: '.editable' jQuery: $ sidebar: disabled: true toolbar: disabled: true # does not work Mark element with class <div class="editable notoolbar"></div> Use event: Aloha.ready(function () { var $ = Aloha.jQuery; Aloha.bind('aloha-editable-activated', function () { if ($(Aloha.activeEditable.obj[0]).hasClass("notoolbar")) { $(".aloha-toolbar").hide(); } }); }); You can just hide it with css such as: div.aloha-toolbar { display: none !important; } There is no

Aloha editor: Inserting images/pictures

落爺英雄遲暮 提交于 2019-12-03 15:23:40
I'm using Aloha editor for editing content on a website powered by PHP and MySQL. It's working fine, but I need to be able to insert images/pictures. I found an Aloha editor plugin for that. Here are some links: http://labs.tapo-it.com/aloha-editor/image-plugin/ http://aloha-editor.org/wiki/ImagePlugin https://github.com/alohaeditor/Aloha-Plugin-Image There is an example in the first link . However, I can't get the plugin running on the latest version of Aloha editor and jQuery. It fails to load and Chrome says: image.js:30 Uncaught TypeError: Cannot read property 'fn' of undefined I have no

What is a good javascript HTML editor for adding custom HTML elements?

戏子无情 提交于 2019-12-02 05:55:32
问题 I want to create a web-based WYSIWYG HTML editor that allows the user to insert pre-defined HTML elements with certain class or id attributes. For example, any HTML editor allows the user to select some text and click the 'bold' button, and this will wrap the selected text in <b></b> tags. I would like the user to be able to select some text, click a button called 'somebutton' and wrap the selected text in <div class="someclass"></div> , or click a different button and wrap the text in <h1 id

Selection.addRange() is deprecated and will be removed from Chrome

僤鯓⒐⒋嵵緔 提交于 2019-11-28 09:12:49
I recently noticed the following message in chrome's console log, while using aloha editor : aloha.js:14579 - The behavior that Selection.addRange() merges existing Range and the specified Range is deprecated and will be removed in M58, around April 2017. See https://www.chromestatus.com/features/6680566019653632 for more details. While trying to find a replacement, i couldn't find anything besides that they are going to remove it, so i would like to know what are the alternatives for Selection.addRange() to get rid of this message. The trick is to use removeAllRanges() on your selection

Selection.addRange() is deprecated and will be removed from Chrome

佐手、 提交于 2019-11-27 02:41:52
问题 I recently noticed the following message in chrome's console log, while using aloha editor: aloha.js:14579 - The behavior that Selection.addRange() merges existing Range and the specified Range is deprecated and will be removed in M58, around April 2017. See https://www.chromestatus.com/features/6680566019653632 for more details. While trying to find a replacement, i couldn't find anything besides that they are going to remove it, so i would like to know what are the alternatives for