Cab Grid Pro (Version 3+) offers address auto-complete on the taxi booking form via the Google Maps JavaScript API. Google requires you supply an API key to use its auto-complete feature. This is a long string of characters generated by Google so they recognise you when you (your website) make calls (looks up addresses) to the API. You will have to collect your API key from Google once generated, and add it to the ‘Google API Key‘ field in the Cab Grid Pro OPTIONS tab:

Follow these steps to get your Google API key:

Note 1: You must enable both the Google Maps JavaScript API and the Google Places API Web Service. Adding these is described below.

Note 2: This process may vary depending on what you have set up already… For example, you may already have a ‘Project’ or an ‘API key’ generated…

  1. Visit https://console.developers.google.com/apis/
    (You may need to log on to your Google account – assuming you have one – first. If not, you’ll have to sign up. We won’t cover that here.)
  2. Click the ‘Google Maps JavaScript API’ link
    api_library
  3. If required, create a project (or select an existing one – see step 4)
    api_manager_-_nimbus_website
    Give the new project a name and click CREATE
    api_manager
  4. Enable the API
    api_manager_-_nimbus_website-3
  5. Go to CREDENTIALS
    api_manager-3
  6. Click ‘Find out what credentials you need?’ and copy the contents of the ‘Here is your API key’ box.
    Your API key should be a long string of characters (upper/lower case and numbers)
    credentials_wizard_-_nimbus_website
  7. Set restrictions (optional – recommended)
    Your key may not function correctly if you do not fully specify the domain names used to access your site (e.g. yoursite.com & yoursite.net)
  8. Add the Google Places API Web Service to your project
    Form your Google Developer Console Dashboard click ‘Enable API‘, then click ‘Google Places API Web Service


    Click ‘ENABLE‘ to add to your project:

Now you have your API key on your computer’s clipboard, you can return to your WordPress admin and paste it into the ‘Google API key’ field under the OPTIONS tab on the Cab Grid Pro admin page.

Country Bias: The auto-complete field will attempt to find addresses based on the user’s location unless you set a country bias. It’s best to select the country where you primarily operate to insure accurate address lookups.

Be sure to click SAVE at the bottom.

Now the booking form will attempt to auto-complete addresses entered.

If you leave the Google API Key field blank, a regular text box will be used. Customers can still add any content (such as flight number or other details) in the ‘Pick Up’ and ‘Destination’ boxes with or without the API.

Tags: , , , ,

Pin It on Pinterest

Share This

Share this post with your friends!