Module: ActiveScaffold::TinyMceBridge::FormColumnHelpers
- Defined in:
- lib/six-updater-web/vendor/plugins/active_scaffold/lib/bridges/tiny_mce/lib/tiny_mce_bridge.rb
Instance Method Summary collapse
Instance Method Details
#active_scaffold_input_text_editor(column, options) ⇒ Object
19 20 21 22 23 24 25 |
# File 'lib/six-updater-web/vendor/plugins/active_scaffold/lib/bridges/tiny_mce/lib/tiny_mce_bridge.rb', line 19 def active_scaffold_input_text_editor(column, ) [:class] = "#{[:class]} mceEditor #{column.[:class]}".strip html = [] html << send(override_input(:textarea), column, ) html << javascript_tag("tinyMCE.execCommand('mceAddControl', false, '#{[:id]}');") if request.xhr? html.join "\n" end |
#onsubmit ⇒ Object
27 28 29 30 |
# File 'lib/six-updater-web/vendor/plugins/active_scaffold/lib/bridges/tiny_mce/lib/tiny_mce_bridge.rb', line 27 def onsubmit submit_js = 'tinyMCE.triggerSave();this.select("textarea.mceEditor").each(function(elem) { tinyMCE.execCommand("mceRemoveControl", false, elem.id); });' if using_tiny_mce? [super, submit_js].compact.join ';' end |