Loading ...
Sorry, an error occurred while loading the content.

Re: Dynamic Menu doesn't display in Safari

Expand Messages
  • soniamtz
    Hi Every one: I found the solution for my problem, only add a node in declaration of in html from Safari detect element where gone the menu bar. The code
    Message 1 of 2 , Jun 4, 2007
    • 0 Attachment
      Hi Every one:

      I found the solution for my problem, only add a node in
      declaration of <ul> in html from Safari detect element where gone
      the menu bar.

      The code is some like this.
      <div id="menu" style="float:left;" class="yuimenubar">
      <div class="bd"><ul class="first-of-
      type"><li>.</li></ul></div>
      </div>


      And agregate the clear content of menu before the call of
      function to fill the menu like this:
      oMenuBar.clearContent();
      FillMenuBar(data);

      Thanks


      --- In ydn-javascript@yahoogroups.com, "soniamtz" <soniamtz@...>
      wrote:
      >
      > Hi every one,
      >
      > I've create a dynamic menu in the version of yui 2.2.2 and it
      > display OK in FireFox and Internet Explorer, but in Safari 2.0.4
      > don't display anything.
      >
      > The code from create this menu in JavaScript is:
      >
      > <script type="text/javascript" language="javascript">
      > var xianoMenuBar;
      > function xianLlenaMenu2()
      > {
      > var xianMenudisplay=[{text:"Menu1", onclick:
      > {fn:xianCargarDatos,obj:"1,c1"}, submenu:{ id:"c1", itemdata:
      > [{text:"Dato1Menu1",
      onclick:fn:xianCargarDatos,obj:"2,p1,REFO"}}]}},
      > {text:"Menu2", onclick:{fn:xianCargarDatos,obj:"1,c2"}, submenu:{
      > id:"c2", itemdata:[{ text:"Dato1Menu2", onclick:
      >
      {fn:xianCargarDatos,obj:"2,p2,CANC"}},
      > { text:"Dato2Menu2", onclick:
      {fn:xianCargarDatos,obj:"2,p2,CJ"}},
      > { text:"Dato3Menu2", onclick:{fn:xianCargarDatos,obj:"2,p2,DIAM"}},
      {
      > text:"Dato4Menu2", onclick:
      >
      {fn:xianCargarDatos,obj:"2,p2,IN"}}]}},
      > {text:"Menu3", onclick:{fn:xianCargarDatos,obj:"1,c3"}, submenu:{
      > id:"c3", itemdata:[{ text:"Dato1Menu3", onclick:
      > {fn:xianCargarDatos,obj:"2,p3,CLVJ"}},{ text:"Dato2Menu3", onclick:
      >
      {fn:xianCargarDatos,obj:"2,p3,MURA"}}]}},
      > {text:"Menu4", onclick:{fn:xianCargarDatos,obj:"1,c4"}, submenu:{
      > id:"c4",itemdata:[{ text:"Dato1Menu4", onclick:
      >
      {fn:xianCargarDatos,obj:"2,p4,NOCO"}}]}}];
      >
      > xianoMenuBar.addItems( xianMenudisplay );
      > xianoMenuBar.render();
      > }
      >
      > function xianCargarDatos( type,args,obj)
      > {
      > alert("click menu");
      > }
      >
      > function init() {
      > xianoMenuBar = new YAHOO.widget.MenuBar("dvmenuPlazas", {
      > autosubmenudisplay:true, showdelay:250, hidedelay:750,
      > lazyload:true });
      >
      > xianLlenaMenu2();
      > }
      >
      > YAHOO.util.Event.addListener(window, "load", init);
      >
      > </script>
      >
      >
      > And this display in the follow div section.
      >
      > <div id="dvmenuPlazas" style="float:left;" class="yuimenubar">
      > <div class="bd"><ul class="first-of-type"><!-- --
      > ></ul></div>
      > </div>
      >
      > I have a old version to this menu in yui 0.11.4 and this works
      fine
      > in Safari.
      >
      > I would be appreciate any suggestion.
      >
      > And other think, I can't configurate the images from submenu
      > indicator, how i do this?
      >
      >
      > Thanks in advanced
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.