I’m following the standard of W3C here http://www.w3.org/TR/CSS2/ui.html and here http://www.quirksmode.org/css/cursor.html#note. However, the element isn’t displayed the hand when mouseover. Please help.
<a style="cursor:pointer;cursor:hand" onclick='javascript:window.open("http://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>&t=<?php single_post_title(); ?>", "_blank", "toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=no,copyhistory=no,left=300,top=100,width=626,height=436")'>[image goes here]</a>
When viewing with IE9 and mouseover, it doesn’t change the cursor into the “hand”, but it’s just the regular arrow instead. Please advise.
Thanks!
Advertisement
Answer
It should be cursor: pointer;
alone because hand
is a proprietary value only implemented by old versions of IE, and is thus an invalid value.
If you actually care about IE 5.x, though, you switch the two properties around, i.e. (cursor: hand; cursor: pointer
, hand comes first). Your CSS will still invalidate though, so I’d rather you not bother.