Jump to content

[Resolvido] Alterar propriedade de div


TMota

Recommended Posts

Boas Gente

Preciso da vossa ajuda, como já devem adivinhar!

A ideia é a seguinte: Quando houver um mouseover na imagem preciso que altere a propriedade da div (que troque o estado de invisivel para visivel), e depois que faça o contrario, onmouseout volte a ocultar a div! Eu exprimentei o seguinte código mas não está a funcionar.

Como é que posso solucionar, sem ter que recorrer a jquery ou a outro tipo de linguagem?

Imagem:

<img src="images/gallery_decor_normal.png" width="150" onmouseover="this.src='images/gallery_decor_hover.png', this.width='200', document.documentElement.client.style='display:show'" onmouseout="this.src='images/gallery_decor_normal.png', this.width='150'">

Div:

<div id="client" style="display:none">XPTO 1</div>

Tiago Mota - www.tiagomota.pt

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.