2 Replies Latest reply on Apr 1, 2008 3:16 PM by Nick Belaevski

    menuItem not working with RF 3.2.0 and JSF RI 1.2_08

    Bjoern Eickvonder Newbie

      I use RF 3.2.0 with Facelets 1.1.14 and JSF RI 1.2_08 on Websphere 6.1. If I use a menuItem in DropDownMenu the following div gets generated:

      <div class="dr-menu-item dr-menu-item-enabled rich-menu-item rich-menu-item-enabled " id="j_id7:j_id28" onclick="this.className='dr-menu-item dr-menu-item-enabled rich-menu-item rich-menu-item-enabled '; {var form = A4J.findForm(this);var params = new Object();params['j_id7:j_id28:hidden'] = 'j_id7:j_id28';Richfaces.jsFormSubmit('j_id7:j_id28',form.id,'',params);}; return false;;" onmouseout="if (RichFaces.Menu.isWithin(event, this)) return; this.className='dr-menu-item dr-menu-item-enabled rich-menu-item rich-menu-item-enabled '; $('j_id7:j_id28').style.cssText=';'; $('j_id7:j_id28:icon').className='dr-menu-icon rich-menu-item-icon '; Element.removeClassName($('j_id7:j_id28:anchor'), 'rich-menu-item-label-selected');" onmouseover="if (RichFaces.Menu.isWithin(event, this)) return; this.className='dr-menu-item dr-menu-item-hover rich-menu-item rich-menu-item-hover ';; $('j_id7:j_id28').style.cssText='; ; ;'; $('j_id7:j_id28:icon').className='dr-menu-icon dr-menu-icon-selected rich-menu-item-i?on rich-menu-item-icon-selected '; Element.addClassName($('j_id7:j_id28:anchor'), 'rich-menu-item-label-selected');" onmouseup="Event.stop(event); " style="; ">

      Note the question mark in the style class "rich-menu-item-i?on" within the onmouseover code. Somehow an invalid character gets into the output stream, such that firefox will not display the page at all. It did work with RF 3.1.4, but maybe only because the onmouseover statement has been much shorter in that version, it is not a typo within RF 3.2.0, i looked into the sources and MenuItemRenderer class is generated correctly. For me it seems to be that the ResponseWriter by Suns RI does bad if an attribute is quite long, because with MyFaces 1.2.2 it is all working well.

      Should MyFaces JSF implementation generally preferred over Suns RI for using with RichFaces, is it better? May it be that developers of RichFaces are also active in MyFaces (resulting in a better combination) or is it just coincidence that MyFaces 1.2.2 and RichFaces 3.2.0 has been released on the same date?