I have not worked with image maps but the way it should work for other elements is:
Cursor attribute is applied when the mouse is over the element, so you should not need the onmouseover. Just use
<area shape="rect" coords="0,61,121,140" style="cursor: pointer;">
Now if you want the "finger" cursor here is what I came up with....
__________________ Vladdy | KL "Working web site is not the one that looks the same on common graphical browsers running on desktop computers, but the one that adequately delivers information regardless of device accessing it"
Originally posted by Vladdy I have not worked with image maps but the way it should work for other elements is:
Cursor attribute is applied when the mouse is over the element, so you should not need the onmouseover. Just use
<area shape="rect" coords="0,61,121,140" style="cursor: hand;">
:D :D Now if you want the "finger" cursor here is what I came up with.... :D :D
Thank you Vladdy for the "finger". Hand would work just fine, but the script still does not work.
Can you please post the link to the page you are working on, that way it would be easier for everyone to analyse the problem you are experiencing. Also, be aware that IE4 and NS4 do not really support CSS and you may not be able to achieve the desired effect in those browsers. Consider breaking your image into seperate pieces the way your map is defined and putting them inside <a> tags with href defined as href="Javascript: scr_valid(1)"
__________________ Vladdy | KL "Working web site is not the one that looks the same on common graphical browsers running on desktop computers, but the one that adequately delivers information regardless of device accessing it"
If you are going to use W3C standard DOM scripting, why use invalid CSS2 property values?
"pointer" is the correct value to get the link pointer, "hand" is an invalid value supported by IE4 before the CSS2 specs were finalized. "pointer" is supported in IE6/Gecko/Opera.
__________________ Vladdy | KL "Working web site is not the one that looks the same on common graphical browsers running on desktop computers, but the one that adequately delivers information regardless of device accessing it"
Why are you bringing up a seven year old thread and then just post useless crap? If you want to get rid of the dotted outline then set the outline style to “none” in the stylesheet.
Hi Guys, Here is the perfect way to handle this for ALL situations with NO javascript
css rule ->
Code:
a:hover{
cursor: pointer;
}
My fave use is for menus or tabs that perform ajax actions as achors need not have a target to have them appear as links
ie. <a>link</a> instead of <a href="whatever">link</a>
Another Tip...
If a number of links are calling the same function
Instead of assigning id's to all links u will use in js,
set an id to the containing div and use:
Code:
window.onload = init;
function init(){var menu = document.getElementById("linksDivId");
var allLinks = menu.getElementsByTagName("a");
for(i = 0; i < allLinks.lenght; i++){
allLinks[i].onclick = clickHandler;
}}function clickHandler()
{
//Whatever you want to put here, use 'this' to reference allLinks[i]
}
The time I spent perfecting use cross of js and css was the best time ive ever spent regarding manipulation and interaction