array ( 'name' => 'tinymce_c', 'studio' => 'visible', 'label' => 'LBL_TINYMCE', 'span' => 12, ),
'type' => 'htmleditable_tinymce', 'dismiss_label' => true, 'span' => 12, 'tinyConfig' => array( // Location of TinyMCE script 'script_url' => 'http://{Instance URL}/include/javascript/tiny_mce/tiny_mce.js', 'height' => '100%', 'width' => '100%', // General options 'theme' => 'advanced', 'skin' => 'sugar7', 'plugins' => 'style,paste,inlinepopups', 'entity_encoding' => 'raw', 'forced_root_block' => false, // Theme options 'theme_advanced_buttons1' => "code,separator,bold,italic,underline,strikethrough,separator,bullist,numlist,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,forecolor,backcolor,separator,fontsizeselect", 'theme_advanced_toolbar_location' => "top", 'theme_advanced_toolbar_align' => "left", 'theme_advanced_statusbar_location' => "none", 'theme_advanced_resizing' => false, 'schema' => 'html5', 'template_external_list_url' => 'lists/template_list.js', 'external_link_list_url' => 'lists/link_list.js', 'external_image_list_url' => 'lists/image_list.js', 'media_external_list_url' => 'lists/media_list.js', 'theme_advanced_path' => false, 'theme_advanced_source_editor_width'=> 500, 'theme_advanced_source_editor_height'=> 400, 'inlinepopups_skin' => 'sugar7modal',17. The array should now be similar to the following:
//Url options for links 'relative_urls' => false, 'remove_script_host' => false, ),
array( ‘name’ => ‘tinymce’, 'type' => 'htmleditable_tinymce', ... 'remove_script_host' => false, ),18. Replace ‘{Instance URL}’ with the URL path to your Sugar Instance. For example, ‘sugarcrm.mycompany.com’.
I just found a quick and dirty fix for firefox. So, I add also the _render function in my custom tinymce field and I set one second delay to render the view.
My code looks like this right now:
// /custom/modules/<MyCustomModule>/clients/base/fields/htmleditable_tinymce/htmleditable_tinymce.js
({
extendsFrom: 'Htmleditable_tinymceField',
_render: function () {
var self = this
this.destroyTinyMCEEditor();
app.view.Field.prototype._render.call(this);
this._getHtmlEditableField().attr('name', this.name);
if (this._isEditView()) {
this._renderEdit(this.options.def.tinyConfig || null);
} else {
setTimeout(function(){
self._renderView(); // here is the trick
},1000)
//this._renderView();
}
},
initTinyMCEEditor: function (optConfig) {
// ....
}
})
Any suggestions are welcome
I just found a quick and dirty fix for firefox. So, I add also the _render function in my custom tinymce field and I set one second delay to render the view.
My code looks like this right now:
// /custom/modules/<MyCustomModule>/clients/base/fields/htmleditable_tinymce/htmleditable_tinymce.js
({
extendsFrom: 'Htmleditable_tinymceField',
_render: function () {
var self = this
this.destroyTinyMCEEditor();
app.view.Field.prototype._render.call(this);
this._getHtmlEditableField().attr('name', this.name);
if (this._isEditView()) {
this._renderEdit(this.options.def.tinyConfig || null);
} else {
setTimeout(function(){
self._renderView(); // here is the trick
},1000)
//this._renderView();
}
},
initTinyMCEEditor: function (optConfig) {
// ....
}
})
Any suggestions are welcome