Forums

[Plugin: Inline Google Maps] 2 JS Bugs. (2 posts)

  1. ragaskar
    Member
    Posted 3 years ago #

    2 bugs exist in the JavaScript file: googlemapsPlugin.js:

    1. Line 498 contains a typo which prevents the title/rel pref switch from working correctly. Currently reads:

    this.userRelAttribute = _useRelAttribute;

    It should read

    this.useRelAttribute = _useRelAttribute;

    IE. there is a lowercase r in between use and Rel in the this var.

    2. More of a doc bug... Google Maps cannot be relied on to produce map links that include 'http://maps.google.' required on 185. For example, if you get to google maps via http://www.google.com/maps, you'll get a http://www.google.com/maps prefix, which fails. I would recommend either regexing a valid google url -- something like http://(.*).google.com, or just tossing an alert when you get a bad link. Sure, alerts kinda suck, but in this case it would've saved me troubleshooting time, and might make a huge difference to the less technical people using your fantastic plugin.

    Thanks for writing this and thanks for sharing the code with us!

  2. avibrazil
    Member
    Posted 2 years ago #

    I just fixed the first problem and I'm uploading the new version. You should see an update on your WP plugins page.

    Abaout the second problem, I've never see a URL with http://www.google.com/maps. Would you point me one, please ?

    Thank you,
    Avi

Topic Closed

This topic has been closed to new replies.

About this Topic