Dark Knight Posted November 11, 2007 Share Posted November 11, 2007 i'm having a problem with this code: onMouseover="this.style.border: 1px solid #000000;" onMouseout="this.style.border: 1px solid #FFD700;" This code should change the border of a cell when the mouse is over that cell. but it dosen't work. where is the problem? thanks for your posts. Link to comment Share on other sites More sharing options...
Synook Posted November 11, 2007 Share Posted November 11, 2007 You need to use the assingment operator (=) onmouseover="this.style.border = '1px solid #000000'" onmouseout="this.style.border = '1px solid #FFD700'" Link to comment Share on other sites More sharing options...
ScottR Posted November 11, 2007 Share Posted November 11, 2007 You could also use CSS: #id {border-color: #000000;}#id:hover {border-color: #FF0000;} Where id is the id of your element, and the border-color is the hexidecimal or named color of your choice. Link to comment Share on other sites More sharing options...
Synook Posted November 12, 2007 Share Posted November 12, 2007 The above solution will not work in IE 6- unless it is a link. Link to comment Share on other sites More sharing options...
SpOrTsDuDe.Reese Posted November 13, 2007 Share Posted November 13, 2007 Try assigning an element to the cell. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.