Search code examples
javascripthtmlpluginstooltipimagemap

Start with a tooltip displayed and area highlighted?


Great plugin with awesome documentation.

I want to know if there is a way to have the map load with an area already highlighted, and a tool-tip for that area already displayed.

Here's my fiddle:

See My Fiddle Code

If it could start with the key northwest highlighted (not selected) and a tooltip that would be great.

has been messing with it for a bit but can't figure this out.

Thanks in advance!


Solution

  • It works in this ImageMapster demo when I add this:

    SEE FIDDLE

        $(function(){
    
             $('area[state="OR"]').mapster('set',true);
    
        });  
    

    For your Fiddle I could also do it. Like this

    .mapster('set', true, 'northwest');

    Your fiddle