Google Server (Browser) Key for WPSLP

Get  Google API Keys

This section pertains to the WordPress Store Locator Plus plug-in   which is the free base plugin for those WordPress administrators who are controlling the plugin and updates.  If you are a subscriber to  MySLP, our fully managed locator SaaS service, you can ignore this page.

Before you get started you will need to get a Google Maps Javascript API Key.

Please note, there are some misleading instructions in the Google developer console telling you to  create a browser-restricted API key when you move your site to production. You do not need to include any restrictions  but if you do then you will also need a second unique key to add in the second field under the SLP/General settings the Geocoding API key.  Either way you must “enable” both the Maps  and Geocoding APIs. Updates to how Google APIS are deployed and the explanation can be found in Google Platform  When you create your project , obtain  your Maps Javascript API  .  The geocoding API is now contained under the “Places” API. The APIS you will need  are now contained under Maps, and Places.  Check to see that both boxes are enabled for your project. View the support documents under Google Product updates for more information. They have added many different APIs. The ones you need for WPSLP to work properly are the two in the screenshot below, referred to as Maps Javascript and geocoding (not to be confused with geolocation). The Geocoding API  converts addresses into geographic coordinates (geocoding), which you can use to place markers or position the map. This API also allows you to convert geographic coordinates into an address (reverse geocoding).

Step 1: Go To the Google Developer Site

Q: Some of the Map Markers are not where I know they should be how do I fix this?

When a location is added into your SLP data set, you will see a message “Store Locator Plus wants you to know:”  and the output of the Latitude and Longitude where Google thinks the location is.

For Example, I added Sydney Opera House and no street address, just name, the city and the country Australia:

“Google thinks Sydney Australia is at lat: -33.8674869 long 151.2069902”

Store Locator Plus Handles Large Location List Imports

Some clients have datasets of 200,000 locations, none of which include latitude/longitude coordinates, only U.S. street addresses. Often customers want to know import limitations  including Google’s limit.  As of June 11, 2018 those geocoding limits will change. You will have a pay as you go billing requirement. You  will need to reconsider how to import, how often to import , and whether to break the list into smaller chunks , or skip geocoding, or switch to the MYSLP SaaS managed service.

In order to perform bulk location imports with a CSV file for the WPSLP plugin you will need the Power add-on installed.  WPSLP Power add-on does not alleviate the need for you to obtain your own API key.  MySLP users  do not need to obtain their own API keys but will need the Professional level plan or higher to import and may have limitations according to the plans.

Importing Large Lists into Store Locator Plus

Import features are available with the Power Add-on

Load Data

If checked , use the faster MySQL Load Data method of file processing. Only base plugin data can be loaded, see the approved field name list.

This feature uses the MySQL Load Data command and is much faster than WordPress / PHP CSV file parsing, with the typical Google Geocoding limitations on performance and record counts (if you are not supplying, filling in the latitude/longitude data fields). This feature will only import basic location data. It does not import extended data fields or category data. If you use this along with  per-entered latitude and longitude values you can import 100,000 locations in less than 10 minutes on a basic web server. The column headers must be included in the file and must match the basic fields. You do NOT need to include all columns.

Location Imports

Location Imports are handled via a CSV file for users that signed up for the MySLP Professional service or are using the WPSLP Power Add On.

CSV Import Format

Getting the proper CSV format can be a challenge when using spreadsheet apps like Excel or Numbers.  Here are some tips to getting a valid CSV format out of a spreadsheet app:

  1. Make sure you always have a header row.  That tells the import process what data is in each column.   The column headers have meaning, so be precise.
  2. When a cell is a text field that STARTS WITH A LEADING ZERO, make sure you explicitly mark the cell as text.   The easiest way to do this is to type a single apostrophe then the number when adding data to the cell as in ‘01886 for the zip code 01886.
  3. Always export with UTF-8 support enabled.
  4. Export to a CSV format.  Comma delimited not tab delimited and quoted strings if given the option.

Check out the Example CSV Imports post to get some usable import files you can play with.