Foros del Web » Programando para Internet » Javascript »

Codigo para accordion

Estas en el tema de Codigo para accordion en el foro de Javascript en Foros del Web. Hola, Soy nuevo, novato y tengo poco que aportar, pero sin embargo pido ayuda... supongo que no es un buen karma para empezar pero procedire ...
  #1 (permalink)  
Antiguo 09/01/2011, 11:50
 
Fecha de Ingreso: enero-2011
Mensajes: 7
Antigüedad: 13 años, 10 meses
Puntos: 0
Codigo para accordion

Hola,
Soy nuevo, novato y tengo poco que aportar, pero sin embargo pido ayuda... supongo que no es un buen karma para empezar pero procedire a exponer mi problema...y si hay algun maestro de corazon grande, lo agradecere.

Me baje un accordion de dynamicdrive y lo instale... el html ok, el css tb ok i java ok...
Me surgio la necessidad de añadir un tercer nivel al menu (header, submenu y subsubmenu..). Asi que lo añadó al html y ok, al css y tb ok.. en el java semi ok... El caso es que de los cinco subsub menus solo se abre el tercero con la opcion click. Me gustaria que se abrieran todos con la opcion mouseover...

Si os parece pegare el codigo y algun entendido le heque un vistazo...


</script>

<script type="text/javascript">

ddaccordion.init({ //para header y submenu
headerclass: "headerbar", //Shared CSS class name of headers group
contentclass: "submenu", //Shared CSS class name of contents group
revealtype: "mouseover", //Reveal content when user clicks or onmouseover the header? Valid value: "click", "clickgo", or "mouseover"
mouseoverdelay: 200, //if revealtype="click", set delay in milliseconds before header expands onMouseover
collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
defaultexpanded: [0], //index of content(s) open by default [index1, index2, etc] [] denotes no content
onemustopen: true, //Specify whether at least one header should be open always (so never all headers closed)
animatedefault: false, //Should contents open by default be animated into view?
persiststate: true, //persist state of opened contents within browser session?
toggleclass: ["", "selected"], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
togglehtml: ["", "", ""], //Additional HTML added to the header when it's collapsed and expanded, respectively ["position", "html1", "html2"] (see docs)
animatespeed: "normal", //speed of animation: integer in milliseconds (ie: 200), or keywords "fast", "normal", or "slow"
oninit:function(headers, expandedindices){ //custom code to run when headers have initalized
//do nothing
},
onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
//do nothing
}
})

ddaccordion.init({ //Para submenu y subsubmenu
headerclass: "submenu", //Shared CSS class name of headers group
contentclass: "subsubmenu", //Shared CSS class name of contents group
revealtype: "mouseover", //Reveal content when user clicks or onmouseover the header? Valid value: "click", "clickgo", or "mouseover"
mouseoverdelay: 200, //if revealtype="click", set delay in milliseconds before header expands onMouseover
collapseprev: false, //Collapse previous content (so only one open at any time)? true/false
defaultexpanded: [], //index of content(s) open by default [index1, index2, etc] [] denotes no content
onemustopen: false, //Specify whether at least one header should be open always (so never all headers closed)
animatedefault: false, //Should contents open by default be animated into view?
persiststate: false, //persist state of opened contents within browser session?
toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
togglehtml: ["", "", ""], //Additional HTML added to the header when it's collapsed and expanded, respectively ["position", "html1", "html2"] (see docs)
animatespeed: "normal", //speed of animation: integer in milliseconds (ie: 200), or keywords "fast", "normal", or "slow"
oninit:function(headers, expandedindices){ //custom code to run when headers have initalized
//do nothing
},
onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
//do nothing
}
})

</script>

Etiquetas: acordeon
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 09:12.