Jump to content

Image hover in a table menu


spoki0

Recommended Posts

So I am trying to make the "buttons" in a menu change when the cursor is rolling over the different buttons.It is in a table with 4 rows and 1 column, the 4 rows all got the same background image. The table again is placed in an ApDiv in order to move it around.The related HTML so far:

<body><div id="apDiv">  <table width="150" height="200" border="0" cellpadding="0" cellspacing="0" background="Button.png" id="Menu">    <tr>      <td height="50"> </td>    </tr>    <tr>      <td height="50"> </td>    </tr>    <tr>      <td height="50"> </td>    </tr>    <tr>      <td height="50"> </td>    </tr>  </table></div></body>

and the CSS

#apDiv {	position:absolute;	left:250px;	top:100px;	width:200px;	height:auto;	z-index:1;}

Note: Button is just shortened location of the image. The image I want to display during hover is named ButtonHover

Link to comment
Share on other sites

I would look up lists, HTML in Google, or right here on the W3Schools site. It's a far better practice for what you are trying to accomplish, and many great navigation menu's have been created using them, most of them involving the hover pseudo-class.

Link to comment
Share on other sites

I would look up lists, HTML in Google, or right here on the W3Schools site. It's a far better practice for what you are trying to accomplish, and many great navigation menu's have been created using them, most of them involving the hover pseudo-class.
Right.Here's the W3Schools link for lists:http://w3schools.com/html/html_lists.aspAnd here's the pseudo-class link:http://w3schools.com/css/css_pseudo_classes.asp
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...