Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Árni Gunnar Ragnarsson 31 posts 51 karma points
    Feb 24, 2011 @ 21:25
    Árni Gunnar Ragnarsson
    0

    Using tinyMCE in custom section

    Hi all.

    I am creating a custom section in Umbraco 4.6.1, where I need to use the tinyMCE editor for some content. I have searched this forum like crazy, but not found anything useful.

    TabPage tab = ItemTabView.NewTabPage("Content");
    
    tab.Menu.NewElement("div""tinymce_toolbar""tiny-mce", 0);
    DataTypeDefinition dataTypeDefinition = DataTypeDefinition.GetDataTypeDefinition(-87);
    umbraco.editorControls.tinyMCE3.TinyMCE editor = (umbraco.editorControls.tinyMCE3.TinyMCE)dataTypeDefinition.DataType.DataEditor;
    if (editor.config["umbraco_toolbar_id"] != null) {
    editor.config.Remove("umbraco_toolbar_id");
    }
    editor.config.Add("umbraco_toolbar_id""tinymce_toolbar");
    tab.Controls.Add(editor);

    The error I am getting is this:

    document.getElementById(ed.getParam("umbraco_toolbar_id", "*")) is null
    document.getElementByI...o_toolbar_id", "*")).appendChild(c);

    Any of you guys and gals have any idea what is going on ?

Please Sign in or register to post replies

Write your reply to:

Draft