Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Maps API Referer 403 Error

Tags:

google-maps

My website uses the Google maps API (3.0) in a very heavy way. I had to register my application with Google APIs Console.

In the "referers" section I put *.websitename.com/* (there is * at the start and at the end), but when I try to access maps from http://websitename.com it doesn't work and appear, and a Google message appears in the console saying it's unauthorized from this referrer (403 Error).

How can I write the "referers" to allow both

http://www.websitename.com

and

http://websitename.com

as referers?

like image 685
user1176552 Avatar asked Aug 27 '13 13:08

user1176552


1 Answers

There is no single pattern that matches both cases, you must use 2 referers

*.websitename.com/*
websitename.com/*

EDIT : Keep in mind that sometimes it needs 5 minutes for changes to take effect.

like image 83
Dr.Molle Avatar answered Oct 31 '22 01:10

Dr.Molle