Staggan Posted December 24, 2011 Share Posted December 24, 2011 Hello I am trying to change my mouse pointer when it hovers over a table element This is where I create my table elements: $genTableArray[$rowIndex][] = "<td rowspan='{$rowspan}' onClick=LinkTo(this) >{$familyTreeArray[$personIndex]} $dob </td> \n"; }} I tried this: $genTableArray[$rowIndex][] = "<td rowspan='{$rowspan}' style="color:#2172A1" onMouseOver="this.style.color='white';this.style.backgroundColor='#2172A1'; this.style.cursor='hand';" onClick=LinkTo(this) >{$familyTreeArray[$personIndex]} $dob </td> \n"; }} But my editor throws a fit... Any ideas? Link to comment https://forums.phpfreaks.com/topic/253796-change-pointer-on-mouse-over-table-element/ Share on other sites More sharing options...
scootstah Posted December 24, 2011 Share Posted December 24, 2011 "hand" is not a cursor. You want pointer. And you don't need Javascript for this, you can just do it with CSS. td:hover { cursor:pointer; } Link to comment https://forums.phpfreaks.com/topic/253796-change-pointer-on-mouse-over-table-element/#findComment-1301147 Share on other sites More sharing options...
ManiacDan Posted December 25, 2011 Share Posted December 25, 2011 cursor: hand; That's how you defined a "hand" cursor in IE6 (and 7 under compatibility mode). In the past I've found that this works: cursor: pointer; cursor: hand; Link to comment https://forums.phpfreaks.com/topic/253796-change-pointer-on-mouse-over-table-element/#findComment-1301217 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.