Pessoal.
Tenho um menu dakeles q vc coloca o mouse em um link e aparece varias opcoes usando <div> so q o problema é q nunca consegui fazer ele alinhar com a pagina centralizanda quando muda a resolucao do vide de 800x600 pra outras maoires, o site fica centralizado mais o menu fica torto.
Tem jeito isso
Como Fazer O Menu Ficar Se Alinhar Junto A Pagina
Started By umbu, 05/08/2005, 10:12
2 replies to this topic
#1
Posted 05/08/2005, 10:12
#2
Posted 05/08/2005, 12:32
manda o código aí pra gente ver...
kaduzick - The Nerds
#3
Posted 05/08/2005, 17:48
La vai os codes:
menus em div:
code JS do menu:
Code pra chamar o menu:
É isso ai tem um site com esse mesmo codigo mais no dele funciona quando a page ta centralizada os menus ficam no lugar certo tbm..
Se algume conhecer um codigo melhor que resolva meu problema aceito tbm obrigado.
menus em div:
<DIV id=div_hospedagem onmouseover="over('hospedagem');" style="VISIBILITY: <? echo"hidden"; ?>; POSITION: absolute; TOP: 58px;" onmouseout="out('hospedagem');"><IMG id=hospedagem height=0 width=0> <table width="126" border="0" cellpadding="0" cellspacing="0" style="MARGIN-LEFT: 243px; background:#D8E2E7; border-left:#8FA3AE 1px solid; border-right:#8FA3AE 1px solid; border-bottom:#8FA3AE 1px solid; border-top:#FFFFFF 2px solid;"> <tr> <td height="18" noWrap style="background:#D8E2E7; border-bottom:#FFFFFF 1px solid;" scope="col" onMouseOver='this.style.backgroundColor=0xB0C1C8' onMouseOut='this.style.backgroundColor=0xD8E2E7'><div align="left" class="texto_menu"><a href="index.php?pagina=Planos.Hospedagem">Planos Hospedagem</a></div></td> </tr> <tr> <td height="18" style="background:#D8E2E7; border-bottom:#FFFFFF 1px solid;" onMouseOver='this.style.backgroundColor=0xB0C1C8' onMouseOut='this.style.backgroundColor=0xD8E2E7'><div align="left" class="texto_menu">Planos Streaming</div></td> </tr> <tr> <td height="18" style="background:#D8E2E7; border-bottom:#FFFFFF 1px solid;" onMouseOver='this.style.backgroundColor=0xB0C1C8' onMouseOut='this.style.backgroundColor=0xD8E2E7'><div align="left" class="texto_menu"><a href="http://www.lwh.com.br:2082" target="_blank">Acessar cPanel</a></div></td> </tr> <tr> <td height="18" style="background:#D8E2E7; border-bottom:#FFFFFF 1px solid;" onMouseOver='this.style.backgroundColor=0xB0C1C8' onMouseOut='this.style.backgroundColor=0xD8E2E7'><div align="left" class="texto_menu"><a href="http://www.lwh.com.br/helpcenter/cgi-bin/pdesk.cgi" target="_blank">Acessar Suporte</a></div></td> </tr> <tr> <td height="18" style="background:#D8E2E7; border-bottom:#FFFFFF 1px solid;" onMouseOver='this.style.backgroundColor=0xB0C1C8' onMouseOut='this.style.backgroundColor=0xD8E2E7'><div align="left" class="texto_menu">Tutoriais</div></td> </tr> </table> </DIV>
code JS do menu:
tms=new Array() //Mostra o submenu no mouseover function over(topicImage){ if(typeof(tms[topicImage])!="undefined") clearTimeout(tms[topicImage]) var obj=document.getElementById(topicImage); document.getElementById('div_'+topicImage).style.left = obj.offsetLeft; //findPosX(obj); document.getElementById('div_'+ topicImage).style.visibility="visible" } //Esconde o submenu no mouseout function out(topicImage){ tms[topicImage]=setTimeout('document.getElementById("div_'+ topicImage + '").style.visibility="hidden"',0) } //Troca a cor dos links do menu function troca(topicImage){ document.getElementById(topicImage).style.color="#000000"; } function destroca(topicImage){ document.getElementById(topicImage).style.color="#ffffff"; }
Code pra chamar o menu:
onmouseover="over('hospedagem');" onmouseout="out('hospedagem');"
É isso ai tem um site com esse mesmo codigo mais no dele funciona quando a page ta centralizada os menus ficam no lugar certo tbm..
Se algume conhecer um codigo melhor que resolva meu problema aceito tbm obrigado.
0 user(s) are reading this topic
0 membro(s), 0 visitante(s) e 0 membros anônimo(s)