Rob
Rob

Reputation: 6380

Hiding google map data

I've been working on a google map (v3 of the api) that is plotting 120 markers or so (or will do shortly). If you view the source the map data is for all the see, is it possible to hide this?

I'm not worried about the code that is generating the map, just the data. The data is grabbed from a Wordpress cms.

Upvotes: 1

Views: 176

Answers (1)

aroth
aroth

Reputation: 54856

I think your options mostly boil down to:

  1. Obfuscate the data. Restructure it in such a way that it is difficult to recognize as location data, and inconvenient for other people to work with.

  2. Don't include the data directly in the page body. Fetch it using an AJAX request instead. Determined users will still be able to get the data, but it won't be quite as easy/obvious, and it will not appear when doing a 'view source'.

You could of course combine the two approaches, and have an AJAX request that returns obfuscated data.

Although, your data appears to be names and locations of businesses, so I'm not sure why protecting it is a concern. Presumably any interested party could find the same information in a phone-book (or with a Google search) if they were so inclined.

Upvotes: 1

Related Questions