Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8961003
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T15:47:14+00:00 2026-06-15T15:47:14+00:00

There is an opensource vector maps for sites called jqvmap The problem is that

  • 0

There is an opensource vector maps for sites called jqvmap

The problem is that using ipad or iphone browser it handles clicks incorrectly.
First touch causes onRegionOver event.
Second touch causes onRegionClick event.

How can we modify onRegionOver to make it work on ios as click?

jQuery('#vmap').vectorMap(
{
    map: 'world_en',
    backgroundColor: '#a5bfdd',
    borderColor: '#818181',
    borderOpacity: 0.25,
    borderWidth: 1,
    color: '#f4f3f0',
    enableZoom: true,
    hoverColor: '#c9dfaf',
    hoverOpacity: null,
    normalizeFunction: 'linear',
    scaleColors: ['#b6d6ff', '#005ace'],
    selectedColor: '#c9dfaf',
    selectedRegion: null,
    showTooltip: true,
    onRegionClick: function(element, code, region)
    {
        var message = 'You clicked "'
            + region
            + '" which has the code: '
            + code.toUpperCase();

        alert(message);
    }
});
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T15:47:15+00:00Added an answer on June 15, 2026 at 3:47 pm

    This is how I would go about it.

    First, start by creating a function that detects the type of device being used (Ipad, Iphone, Droid, etc).

    function testDevice(){
        if(/Android|webOS|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent)) {
            return true;
        }else{
            return false;
        }
    }
    

    Next, setup both a regionClick & regionOver event.

    jQuery('#vmap').vectorMap(
    {
        map: 'world_en',
        backgroundColor: '#a5bfdd',
        borderColor: '#818181',
        borderOpacity: 0.25,
        borderWidth: 1,
        color: '#f4f3f0',
        enableZoom: true,
        hoverColor: '#c9dfaf',
        hoverOpacity: null,
        normalizeFunction: 'linear',
        scaleColors: ['#b6d6ff', '#005ace'],
        selectedColor: '#c9dfaf',
        selectedRegion: null,
        showTooltip: true,
        onRegionClick: function(element, code, region)
        {
            if(!testDevice()){ //not mobile device
                var message = 'You clicked "'
                + region
                + '" which has the code: '
                + code.toUpperCase();
    
                alert(message);
            }
        },
        onRegionOver: function(element, code, region)
        {
            if(testDevice()){ //mobile device
                var message = 'You clicked "'
                + region
                + '" which has the code: '
                + code.toUpperCase();
    
                alert(message);
            }
        }
    });
    

    DEMO:

    http://jsfiddle.net/V79hw/5/

    Hope this helps!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any opensource tool built using cURL that downloads a single webpage and
Is there any opensource samples of JQuery usages of StackOverFlow-like sites...... Any help in
Is there any opensource/commercial software that converts ppt, doc, pdf, video, audio into swf
Is there any opensource library that I could use to feed the letters and
Is there any opensource tool in C# that can do a webpage save as
Is there some opensource solution that allows you to do that.I am working on
Is there any opensource library/WPF Control that can act as bitmap editor (e.g. just
Are there any opensource/free libraries that I can use to calculate the LCOM3 or
Is there a PHP class/script (opensource/free) that allows me to send emails with attached
Are there any opensource .Net libraries that handle Flesch-Kincaid readability calculations? Wiki: http://en.wikipedia.org/wiki/Flesch-Kincaid_readability_test

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.