Announcement

Do not use the forums to submit bug reports, feature requests or patches, submit a New Ticket instead.

#1 2009-04-15 10:04:32

jiriki
New member
Registered: 2009-04-15
Posts: 3

Multiple textareas: Can't find the requested dropdown definition

Hey guys,

i am currently integrating the Xinha editor (ver. 0.95) into my WebsiteBaker module. The problem that occurs is with more than two textareas at the same page that have to be replaced by Xinha editors. Up to 2 textareas are no problem but when adding the third textarea (id and name are the same in each textarea but differ between the textareas. i used e.g. 'header', 'footer' and 'footerr') javascript puts the following double post on my screen:

"ERROR [createSelect]: Can't find the requested dropdown definition"
and then
"FIXME: Unknown toolbar item: popupeditor"

This error message-couple is repeated (number of textareas - 1) times. For each message-couple having confirmed it displays one textarea in Xinha style which is fully functional as far as i have checked it.

So, in the end i would prefer to know why this error message is displayed and what i could do about it. Forgot to mention: I tested it with either version 0.93 and 0.95: Result was the same.

Thanks a lot. Greets, Alex

----------------------------------------------
My xinha config file:

    xinha_editors = null;
    xinha_init    = null;
    xinha_config  = null;
    xinha_plugins = null;

    xinha_init = xinha_init ? xinha_init : function() {

      /** STEP 1 ***************************************************************
       * First, what are the plugins you will be using in the editors on this
       * page.  List all the plugins you will need, even if not all the editors
       * will use all the plugins.
       *
       * The list of plugins below is a good starting point, but if you prefer
       * a must simpler editor to start with then you can use the following 
       * 
       * xinha_plugins = xinha_plugins ? xinha_plugins : [ ];
       *
       * which will load no extra plugins at all.
       ************************************************************************/

      xinha_plugins = xinha_plugins ? xinha_plugins :
     [
        'CharacterMap',
        'HtmlEntities',
        'ContextMenu',
        'GetHtml',
        'ImageManager',
        'InsertFile',
        'Linker',
        'ListType',
        'DynamicCSS',
        'SuperClean',
        'TableOperations',
        'Abbreviation',
        'FindReplace',
        'HorizontalRule',
        'InsertAnchor'
    ];
    // THIS BIT OF JAVASCRIPT LOADS THE PLUGINS, NO TOUCHING  :)
    if(!Xinha.loadPlugins(xinha_plugins, xinha_init)) return;

    /** STEP 2 ***************************************************************
    * Now, what are the names of the textareas you will be turning into
    * editors?
    ************************************************************************/

    xinha_editors = xinha_editors ? xinha_editors :
    [
        'introduction','ending','content1','content2','content4','content5'    ];


      /** STEP 3 ***************************************************************
       * We create a default configuration to be used by all the editors.
       * If you wish to configure some of the editors differently this will be
       * done in step 5.
       *
       * If you want to modify the default config you might do something like this.
       *
       *   xinha_config = new Xinha.Config();
       *   xinha_config.width  = '640px';
       *   xinha_config.height = '420px';
       *
       *************************************************************************/

    xinha_config = xinha_config ? xinha_config : new Xinha.Config();

    // Toolbar settings
      xinha_config.toolbar =
    [
            ["popupeditor"],
            ["separator","formatblock","fontname","fontsize","bold","italic","underline","strikethrough"],
            ["separator","forecolor","hilitecolor","textindicator"],
            ["separator","subscript","superscript"],
            ["linebreak","separator","justifyleft","justifycenter","justifyright","justifyfull"],
            ["separator","insertorderedlist","insertunorderedlist","outdent","indent"],
            ["separator","inserthorizontalrule","abbreviation","insert-anchor","createlink","insertimage","inserttable"],
            ["separator","undo","redo","selectall"], (HTMLArea.is_gecko ? [] : ["cut","copy","paste","overwrite"]),
            ["separator","killword","clearfonts","removeformat","toggleborders","splitblock","lefttoright", "righttoleft"],
            ["separator","htmlmode","showhelp","about"]
      ];

      // Load Styles
        xinha_config.pageStyle = 'body { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; }';
    
    // Setup Linker with page paths
        xinha_config.Linker.backend = null;
    xinha_config.Linker.files = [{A LOT OF LINKS}];

    // comment this out, if you dont want encoding of european specialchars:
    xinha_config.HtmlEntities.Encoding= null;
    
    // use GetHTML
    xinha_config.getHtmlMethod='TransformInnerHTML';


      /** STEP 4 ***************************************************************
       * We first create editors for the textareas.
       *
       * You can do this in two ways, either
       *
       *   xinha_editors   = Xinha.makeEditors(xinha_editors, xinha_config, xinha_plugins);
       *
       * if you want all the editor objects to use the same set of plugins, OR;
       *
       *   xinha_editors = Xinha.makeEditors(xinha_editors, xinha_config);
       *   xinha_editors['myTextArea'].registerPlugins(['Stylist','FullScreen']);
       *   xinha_editors['anotherOne'].registerPlugins(['CSS','SuperClean']);
       *
       * if you want to use a different set of plugins for one or more of the
       * editors.
       ************************************************************************/

    xinha_editors   = Xinha.makeEditors(xinha_editors, xinha_config, xinha_plugins);

      /** STEP 5 ***************************************************************
       * If you want to change the configuration variables of any of the
       * editors,  this is the place to do that, for example you might want to
       * change the width and height of one of the editors, like this...
       *
       *   xinha_editors.myTextArea.config.width  = '640px';
       *   xinha_editors.myTextArea.config.height = '480px';
       *
       ************************************************************************/


      /** STEP 6 ***************************************************************
       * Finally we "start" the editors, this turns the textareas into
       * Xinha editors.
       ************************************************************************/

    Xinha.startEditors(xinha_editors);
    window.onload = null;
    }
    window.onload = function() { xinha_init()};

Offline

#2 2009-04-23 17:26:12

jiriki
New member
Registered: 2009-04-15
Posts: 3

Re: Multiple textareas: Can't find the requested dropdown definition

Noone ever had this prob? Any advise welcomed ..

Offline

#3 2009-04-29 11:03:29

douglas
New member
Registered: 2009-04-29
Posts: 5

Re: Multiple textareas: Can't find the requested dropdown definition

I think someone reported this same problem and it is fixed in the nightlies...

Offline

#4 2009-04-29 14:19:13

jiriki
New member
Registered: 2009-04-15
Posts: 3

Re: Multiple textareas: Can't find the requested dropdown definition

Hi, what does nightlies mean? Thanks

Offline

Board footer

Powered by FluxBB