Select the API key that you want to set a restriction on. The API key property page appears.
Under Key restrictions, set the following restrictions:
Application restrictions:
To accept requests from the list of website that you supply, select HTTP referrers (web sites) from the list of Application restrictions.
Specify one or more referrer web sites. For example, *.google.com accepts all sites ending in google.com, such as https://developers.google.com.
Note: file:// referers need a special representation to be added to the key restriction. The "file://" part should be replaced with "__file_url__" before being added to the key restriction. For example, "file:///path/to/" should be formatted as "__file_url__//path/to/*". After enabling file:// referers, it is recommended you regularly check your usage, to make sure it matches your expectations.
API restrictions:
Click Restrict key.
Select Maps JavaScript API from Select APIs dropdown. If the Maps JavaScript API is not listed, you need to enable it.
Hello!
I cant see the map on the web site, on the editor not appear the section where insert a API, or enable Google Maps, can I use a plugin?
Thanks!
Hi!
Thank you for contacting us.
We have inspected your site and seen that you have an RefererNotAllowedMapError error.
Please see the following link. It will guide you how to solve it.
https://developers.google.com/maps/documentation/javascript/error-messages#referer-not-allowed-map-error
Regards, BoldThemes team
If you like our products please consider leaving us a rating. A huge thank you from BoldThemes in advance!
Thanks!
Yes I have the API Key, but I dont founded where insert the code, in which section.
Hi Gabriela!
Did you do the following procedure?
Go to the Credentials page
- To accept requests from the list of website that you supply, select HTTP referrers (web sites) from the list of Application restrictions.
- Specify one or more referrer web sites. For example, *.google.com accepts all sites ending in google.com, such as https://developers.google.com.
API restrictions:Note: file:// referers need a special representation to be added to the key restriction. The "file://" part should be replaced with "__file_url__" before being added to the key restriction. For example, "file:///path/to/" should be formatted as "__file_url__//path/to/*". After enabling file:// referers, it is recommended you regularly check your usage, to make sure it matches your expectations.
- Click Restrict key.
- Select Maps JavaScript API from Select APIs dropdown. If the Maps JavaScript API is not listed, you need to enable it.
- If your project uses Places Library, also select Places API. Similarly, if your project uses other services in the JavaScript API (Directions Service, Distance Matrix Service, Elevation Service, and/or Geocoding Service), you must also enable and select the corresponding API in this list.
To finalize your changes, click Save.Regards, BoldThemes team
If you like our products please consider leaving us a rating. A huge thank you from BoldThemes in advance!