Grow your CSS skills. Land your dream job.

Google Maps Embed Bug

  • # May 18, 2013 at 6:41 pm

    I embed Google maps API v3 onto my website and i’ts working well. But one problem i’m having is that when you click “contact us” then click another tab, and go back to “contact us” section, the map doesn’t fully load. Only a small portion does. This also happens when you click the blue arrow and re-open “contact us” section. Anyone have any idea what’s causing this? http://reallycoolstuff.net/PROJECTS/Unica

    # May 19, 2013 at 6:09 am

    Can’t find out where the bug comes from, but re-calling `initialize();` seems to fix it (put it after fading in #contact_us in index.js)

    # May 19, 2013 at 10:21 am

    @CrocoDillon The map is wrapped in a div and the div is what fades in and out along with whatever is inside it. I don’t fully understand what you mean
    > (put it after fading in #contact_us in index.js)

    # May 19, 2013 at 4:27 pm

    You’re fading in that div (with id ‘contact_us’), line 26 of index.js… if you call `initialize();` right after that, does it work? (initialize is a function you added to global scope that initializes the map, I don’t think it should be in global scope, but for now it might fixes things :P )

    $(“#contact_us_nav”).click(function() {
    $(“#about_us”).fadeOut(200);
    $(“#contact_us”).fadeIn(200);
    $(“#customize”).fadeOut(200);
    initialize();
    });

    # May 19, 2013 at 5:18 pm

    @CrocoDillon That fixed it :D. Thank you.

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".