babyewok Posted June 27, 2016 Share Posted June 27, 2016 The store map does not work and I get this error: Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-errorhttp://maps.google.com/maps/api/js?sensor=true®ion=GBLine 32 Using default istallation of ps 1.6.1.6 Link to comment Share on other sites More sharing options...
babyewok Posted June 28, 2016 Author Share Posted June 28, 2016 Has anyone else expeirenced this problem? Link to comment Share on other sites More sharing options...
Alberto Peripolli Posted June 29, 2016 Share Posted June 29, 2016 Also me Link to comment Share on other sites More sharing options...
SimondeCambon Posted June 30, 2016 Share Posted June 30, 2016 Also me too. Need help please. Link to comment Share on other sites More sharing options...
seongliyn Posted July 1, 2016 Share Posted July 1, 2016 Same here. I think is a bug in Prestashop version 1.6.1.6 Link to comment Share on other sites More sharing options...
babyewok Posted July 2, 2016 Author Share Posted July 2, 2016 Reported to the forge: http://forge.prestashop.com/browse/PSCSX-8179 Link to comment Share on other sites More sharing options...
evomark Posted July 4, 2016 Share Posted July 4, 2016 I also have this issue. "Oops! Something went wrong. This page didn't load Google Maps correctly. See the JavaScript console for technical details." Did someone found a solution? Thanks. Link to comment Share on other sites More sharing options...
evomark Posted July 4, 2016 Share Posted July 4, 2016 Yes, these are the errors and warnings. I'm using 1.6.1.6. The error was also on 1.6.1.5... Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-error Google Maps API warning: NoApiKeys https://developers.google.com/maps/documentation/javascript/error-messages#no-api-keys Google Maps API warning: SensorNotRequired https://developers.google.com/maps/documentation/javascript/error-messages#sensor-not-required Link to comment Share on other sites More sharing options...
evomark Posted July 4, 2016 Share Posted July 4, 2016 Thank you so much mdekker! It is working. You're awesome! 2 Link to comment Share on other sites More sharing options...
babyewok Posted July 4, 2016 Author Share Posted July 4, 2016 Fabulous, thank you - I will check this out tomorrow. Link to comment Share on other sites More sharing options...
SimondeCambon Posted July 5, 2016 Share Posted July 5, 2016 Thanks ! Link to comment Share on other sites More sharing options...
babyewok Posted July 5, 2016 Author Share Posted July 5, 2016 (edited) Works a treat, thanks. On a slighlty different note, if there is only one store, do you know how to show the store address an opening times under the map as well as on it? I also find that the store search facility never finds the store! Edited July 5, 2016 by babyewok (see edit history) Link to comment Share on other sites More sharing options...
seongliyn Posted July 5, 2016 Share Posted July 5, 2016 I installed the Google Maps fix - Store locator module and configure it according to the guide but it still doesn't work. Any idea? 2 Link to comment Share on other sites More sharing options...
seongliyn Posted July 5, 2016 Share Posted July 5, 2016 Wait for cache to clear Hi mdekker, May I know what cache I need to wait for it to be cleared? Can I manually clear it? Link to comment Share on other sites More sharing options...
seongliyn Posted July 5, 2016 Share Posted July 5, 2016 PHP OPCache, since the location to the API key is set in PHP How long do I have to wait? Any way I can manually clear the cache? Link to comment Share on other sites More sharing options...
seongliyn Posted July 6, 2016 Share Posted July 6, 2016 Hmmz, maybe you just used the wrong key, haven't enabled overrides or something like that. I follow the steps in the module and got the key from Google API. Is there something else I missed? Link to comment Share on other sites More sharing options...
abunea Posted July 13, 2016 Share Posted July 13, 2016 Hi mdekker, In my case, your code adds the key at the end of the gmaps url: http://maps.google.com/maps/api/js?&sensor=true®ion=US&AIza.........k instead of http://maps.google.com/maps/api/js?key=AIza....................k&sensor=true®ion=US So for you guys who installed mdekker's code, if you decide to edit /controllers/front/StoresController.php and add the key there it will not work with this module installed and the key field in the module config empty. You will have to unisntall first and clear the smarty or other cache. mdekker, please correct me if i'm wrong. On the other hand, thanks a lot for your advice with the js key. All the best Link to comment Share on other sites More sharing options...
nnd_newbie Posted July 15, 2016 Share Posted July 15, 2016 Map is displayed but searching is not working. If you input any address it says "Not found". On Prestashop version 1.6.1.6 with old domain (thus without api key), searching works. But with new domain and api key does not. Any help? Link to comment Share on other sites More sharing options...
babyewok Posted July 15, 2016 Author Share Posted July 15, 2016 Yes, I have exactly the same issue Link to comment Share on other sites More sharing options...
nnd_newbie Posted July 15, 2016 Share Posted July 15, 2016 Did you try any of the suggested solutions in this topic? Yes and map is displayed correctly. More: I started developing shop with test domain before changes in Google maps. So with test domain I can test both: with and without api key. Without api key all works. When I add api key map is displayed correctly but searching is broken. The only change in code and database is in StoresController. So definitely adding api key solves problem with map but breaks searching. Link to comment Share on other sites More sharing options...
SimondeCambon Posted July 19, 2016 Share Posted July 19, 2016 I have the same problem, the map works but no search. Need help. Link to comment Share on other sites More sharing options...
nnd.newbie Posted July 28, 2016 Share Posted July 28, 2016 Any progress? Link to comment Share on other sites More sharing options...
chirag_0110 Posted July 28, 2016 Share Posted July 28, 2016 Hi All, I have installed ps v1.6.1.6 and faced same issue for google map display. I edit stroreController page as per mdekker suggect. Google map work fine but search not. Please write here if any one found solution. Thanks in advance. Link to comment Share on other sites More sharing options...
chirag_0110 Posted July 28, 2016 Share Posted July 28, 2016 (edited) Hi All, Finally found solution for google map searching issue. We just need to enable following APIs from Google Console. https://console.developers.google.com/apis/library. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API You can see attached screenshot for better under stand. Please do this. It will resolve your issue. Enjoy :) Please make this topic as solved if it resolve your issue. Edited July 5, 2017 by chirag_0110 (see edit history) 5 Link to comment Share on other sites More sharing options...
nnd.newbie Posted July 29, 2016 Share Posted July 29, 2016 We just need to enable following APIs from Google Console. https://console.developers.google.com/apis/library. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API It works for me. Thanks. Link to comment Share on other sites More sharing options...
chirag_0110 Posted July 29, 2016 Share Posted July 29, 2016 It works for me. Thanks. Hi nnd, Most welcome, Glad to hear from you. You can like post if it helps you. Thanks, Chirag Link to comment Share on other sites More sharing options...
markh76 Posted July 29, 2016 Share Posted July 29, 2016 Awesome.. Thank you.. Mark Link to comment Share on other sites More sharing options...
sebaskw Posted August 12, 2016 Share Posted August 12, 2016 Hello, Have used mpgoogle maps fix module but it did not work. It did not input API key into storescontroller.php file. Any idea why? Link to comment Share on other sites More sharing options...
samsootho Posted August 15, 2016 Share Posted August 15, 2016 Hi All, Finally found solution for google map searching issue. We just need to enable following APIs from Google Console. https://console.developers.google.com/apis/library. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API You can see attached screenshot for better inder stand.Screenshot_1.png Please do this. It will resolve your issue. Enjoy :) Please make this topic as solved if it resolve your issue. Hi chirag_0110, how can I apply your solution to my map search issue? My site is http://levanzo.com.my/en/stores Link to comment Share on other sites More sharing options...
acidrush Posted August 15, 2016 Share Posted August 15, 2016 Hi I understand this is work in front, but what about the admin order edit page?I have a same issue in admin order editor google map. Someone can tell me where need to modify? Thanks.... Link to comment Share on other sites More sharing options...
chirag_0110 Posted August 16, 2016 Share Posted August 16, 2016 Hi chirag_0110, how can I apply your solution to my map search issue? My site is http://levanzo.com.my/en/stores Hi samsootho, Nothing need to do from your store (Site). Just need to enable mentioned three APIs from your google developer account. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API Let me know if needed my help. Thanks, Chirag Link to comment Share on other sites More sharing options...
jjbir Posted August 19, 2016 Share Posted August 19, 2016 Hi! How are you? Please, I need some help. The trouble persists. I have edit storeController page as mdekker suggect and I have enable following APIs from Google Console. https://console.developers.google.com/apis/library. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API The text error: - Google Maps API warning: NoApiKeys https://developers.google.com/maps/documentation/javascript/error-messages#no-api-keys util.js:208 - Google Maps API warning: SensorNotRequired https://developers.google.com/maps/documentation/javascript/error-messages#sensor-not-required js?sensor=true®ion=ES&key%3D"AIzaSyCMo4AWsHMCle5cJ1ioj4NbmyR4VwvcLwM":34 - Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-error_.ib @ js?sensor=true®ion=ES&key%3D"AIzaSyCMo4AWsHMCle5cJ1ioj4NbmyR4VwvcLwM":34(anonymous function) @ common.js:51(anonymous function) @ common.js:192c @ common.js:45(anonymous function) @ AuthenticationService.Authenticate?1shttp%3A%2F%2Fcarolinasierra.es%2Fshop%2Findex.php%3Fcontroller…:1 Thank you very much for your time and assistance in this matter. Regards. Joan 1 Link to comment Share on other sites More sharing options...
chirag_0110 Posted August 20, 2016 Share Posted August 20, 2016 Hi! How are you? Please, I need some help. The trouble persists. I have edit storeController page as mdekker suggect and I have enable following APIs from Google Console. https://console.developers.google.com/apis/library. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API The text error: - Google Maps API warning: NoApiKeys https://developers.google.com/maps/documentation/javascript/error-messages#no-api-keys util.js:208 - Google Maps API warning: SensorNotRequired https://developers.google.com/maps/documentation/javascript/error-messages#sensor-not-required js?sensor=true®ion=ES&key%3D"AIzaSyCMo4AWsHMCle5cJ1ioj4NbmyR4VwvcLwM":34 - Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-error_.ib @ js?sensor=true®ion=ES&key%3D"AIzaSyCMo4AWsHMCle5cJ1ioj4NbmyR4VwvcLwM":34(anonymous function) @ common.js:51(anonymous function) @ common.js:192c @ common.js:45(anonymous function) @ AuthenticationService.Authenticate?1shttp%3A%2F%2Fcarolinasierra.es%2Fshop%2Findex.php%3Fcontroller…:1 Thank you very much for your time and assistance in this matter. Regards. Joan Hi Joan, It should only happen if All mentioned google api not enable for your google api key. Can you please confirm once ? May be you enable those apis for another project (API KEY). Link to comment Share on other sites More sharing options...
flagseller Posted August 22, 2016 Share Posted August 22, 2016 Need help! I am totally lost. I have set up the browser api key and enabled three apis including the javascript one. I copied the key to the google map fix module. Not working. Then I manually added it to the controllers/front/StoresController.php. Still not working. Any suggestion? the url is https://addtocontainer.co.nz/stores Many thanks 1 Link to comment Share on other sites More sharing options...
acidrush Posted August 23, 2016 Share Posted August 23, 2016 I have a same issue in admin order delivery address google map.Someone can tell me where need to place the api key for working? Thanks.... Link to comment Share on other sites More sharing options...
wpmidia Posted September 3, 2016 Share Posted September 3, 2016 Good evening, I'm having the same problem on the maps . already created the api key and put on file /controllers/front/StoresController.php put the map appears and disappears then with the message " Oops ! Something went wrong. This page did not load Google Maps correctly. See the JavaScript console to see technical details . " My version of prestashop is 1.6.1.6 . I have another store on the same server and does not occur this problem . I do not know what to do. I appreciate any help . Good evening, I'm having the same problem on the maps . already created the api key and put on file /controllers/front/StoresController.php put the map appears and disappears then with the message " Oops ! Something went wrong. This page did not load Google Maps correctly. See the JavaScript console to see technical details . " My version of prestashop is 1.6.1.6 . I have another store on the same server and does not occur this problem . I do not know what to do. I appreciate any help . Link to comment Share on other sites More sharing options...
samsootho Posted September 3, 2016 Share Posted September 3, 2016 (edited) Hi samsootho, Nothing need to do from your store (Site). Just need to enable mentioned three APIs from your google developer account. Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API Let me know if needed my help. Thanks, Chirag Hi Chirag, thanks for your reply. I have enabled the mentioned APIs, do I need to add the API to anywhere of the website? Best, Sam Edited September 3, 2016 by samsootho (see edit history) Link to comment Share on other sites More sharing options...
samsootho Posted September 3, 2016 Share Posted September 3, 2016 Hi Chirag, thanks for your reply. I have enabled the mentioned APIs, do I need to add the API to anywhere of the website? Best, Sam Hi Chirag, I managed to find the location for API following an earlier post in this topic. Thanks for your advice. You guys are awesome! 1 Link to comment Share on other sites More sharing options...
samsootho Posted September 3, 2016 Share Posted September 3, 2016 Good evening, I'm having the same problem on the maps . already created the api key and put on file /controllers/front/StoresController.php put the map appears and disappears then with the message " Oops ! Something went wrong. This page did not load Google Maps correctly. See the JavaScript console to see technical details . " My version of prestashop is 1.6.1.6 . I have another store on the same server and does not occur this problem . I do not know what to do. I appreciate any help . Good evening, I'm having the same problem on the maps . already created the api key and put on file /controllers/front/StoresController.php put the map appears and disappears then with the message " Oops ! Something went wrong. This page did not load Google Maps correctly. See the JavaScript console to see technical details . " My version of prestashop is 1.6.1.6 . I have another store on the same server and does not occur this problem . I do not know what to do. I appreciate any help . There are 2 easy steps only, go to the following links: Step 1: Get the API --> https://www.prestashop.com/forums/topic/539319-store-map-error-missing-api-key/page-2?do=findComment&comment=2375038 Step 2: Insert the API --> https://www.prestashop.com/forums/topic/539319-store-map-error-missing-api-key/?p=2360228 Link to comment Share on other sites More sharing options...
wpmidia Posted September 3, 2016 Share Posted September 3, 2016 Good morning , I have done these changes and it did not work , the map appears and disappears soon after. Link to comment Share on other sites More sharing options...
Lluvia Posted September 6, 2016 Share Posted September 6, 2016 (edited) Hi there! I had the same problem and tried again and again to have a solution, finally I fixed it. I want to share what worked in my case: Reading the thread some comment said that It would be some problem of the theme... so I have notice that using both solutions in this thread nothing change on the mesages I saw in my Javascript console. I went to the theme support and found that in my case, the theme called Google Maps byself not using StoresController.php so I found the file in my theme (who was a module by my theme´s author) and changed there the API Key.Ah! the varible "sensor is deprecated and not used anymore so use: maps.googleapis.com/maps/api/js?v=3.exp&key=YOUR_API_KEY instead of: maps.google.com/maps/api/js?key=AIzaSyCCXIIFPJD-unvMy-jB7N1ylSEUySJ9JiE&sensor=true®ion= Finally: It detected my API KEY but it doesn´t worked until I put in the entire url as autorized in Google API credentials page, I mean: myurl.com/contact instead of */myurl.com* Hope it helps. Edited September 6, 2016 by Lluvia (see edit history) 1 Link to comment Share on other sites More sharing options...
xarhs Posted September 9, 2016 Share Posted September 9, 2016 Good morning guys I also have about the same problem. when I press click to display the map, only for a moment and post me the error Oops! Something went wrong. This page didn't load Google Maps correctly. See the JavaScript console for technical details I have the impression that something runs after the procedure and annuls the key of api my site is https://essans.gr Link to comment Share on other sites More sharing options...
xarhs Posted September 14, 2016 Share Posted September 14, 2016 I tried all the solutions but refuses to run. I do not know what else to do. Any help is appreciated my site is https://essans.gr 1 Link to comment Share on other sites More sharing options...
Sharak Posted September 16, 2016 Share Posted September 16, 2016 (edited) Need help! I am totally lost. I have set up the browser api key and enabled three apis including the javascript one. I copied the key to the google map fix module. Not working. Then I manually added it to the controllers/front/StoresController.php. Still not working. Any suggestion? the url is https://addtocontainer.co.nz/stores Many thanks Try read more carefuly next time You've assigned your api key to region instead key and that's why google is still blocking your map generation. So to fix this just change //maps.google.com/maps/api/js?sensor=true®ion=[YOUR_API_KEY] to //maps.google.com/maps/api/js?key=[YOUR_API_KEY]&sensor=true®ion= Adding key=[YOUR_API_KEY]& just after .../maps/api/js? in original StoresController.php should be the only change in this file. You may also check Lluvia's fix to get rid of other warnings, but the map should load correctly without it. @xarhs You've made axactly the same mistake. You're welcome Edited September 16, 2016 by Sharak (see edit history) Link to comment Share on other sites More sharing options...
SalvGun Posted September 28, 2016 Share Posted September 28, 2016 Thank you mdekker! It is working!!! You're super! Link to comment Share on other sites More sharing options...
Planes Digital Posted October 11, 2016 Share Posted October 11, 2016 Excellent tutorial. It works all right except that in the search can not find paices But if you let me look provinces streets, etc. Someone help me Excellent tutorial. It works all right except that in the search can not find paices But if you let me look provinces streets, etc. Someone help me Link to comment Share on other sites More sharing options...
Trafiquant Posted October 12, 2016 Share Posted October 12, 2016 (edited) You will now need to visit your Google API Console, request an API key for the Google Maps JavaScript API, and change the file /controllers/front/StoresController.php You can override the StoresController.php in directory /override/controllers/front/ ; I think it's a better idea to not lose this hack in case of minor Prestashop update. Edited October 12, 2016 by Trafiquant (see edit history) Link to comment Share on other sites More sharing options...
crochead Posted October 21, 2016 Share Posted October 21, 2016 Ok, I have followed instructions and still getting error messages "Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-error"js:34:391"Google Maps API warning: NoApiKeys https://developers.google.com/maps/documentation/javascript/error-messages#no-api-keys"util.js:208:33"Google Maps API warning: SensorNotRequired https://developers.google.com/maps/documentation/javascript/error-messages#sensor-not-required" https://mosquitocoilholder.boycott-big-box.com.au/stores have no problem with disabled SSL, but I need the SSL on every page?? Any ideas please Link to comment Share on other sites More sharing options...
SEC Market Posted October 23, 2016 Share Posted October 23, 2016 (edited) I ran into the same problem and solved it (with guide in this topic). It's applicable to any Prestashop 1.6.1.x (tested with 1.6.1.7). Go to the Google API Console. Create or select a project. Click Continue to enable the API and any related services. On the Credentials page, get an API key (and set the API key restrictions). Note: If you have an existing unrestricted API key, or a key with browser restrictions, you may use that key. To prevent quota theft, secure your API key following these best practices. I added the allowed referrers (*.domain.com/*, domain.com/*, https://domain.com/stores) (Optional) Enable billing. See Usage Limits for more information. To search for a shop on the map you must enable Google Maps Geocoding API in your console.developers.google.com Project. Go to /controllers/front/StoresController.php and change at the end of the file line (see file in google drive):https://drive.google.com/open?id=0Bw23y7_XsFjJUnRvQWZSZWdONmc Where YOUR-GENERATED-API-KEY-HERE you must to replace the generated API key. If you have completed step 5, then you need to wait 5 minutes for the changes (during this time you will see an error - dont worry, just wait) PROFIT! P.S. Please do not write anything on this topic until you have done everything in the right order. Edited October 23, 2016 by SEC Market (see edit history) Link to comment Share on other sites More sharing options...
Sharak Posted October 26, 2016 Share Posted October 26, 2016 (edited) Ok, I have followed instructions and still getting error messages "Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-error"js:34:391 "Google Maps API warning: NoApiKeys https://developers.google.com/maps/documentation/javascript/error-messages#no-api-keys"util.js:208:33 "Google Maps API warning: SensorNotRequired https://developers.google.com/maps/documentation/javascript/error-messages#sensor-not-required" https://mosquitocoilholder.boycott-big-box.com.au/stores have no problem with disabled SSL, but I need the SSL on every page?? Any ideas please Your store is disabled so I can't check it out. Have you seen THIS? Edited October 26, 2016 by Sharak (see edit history) Link to comment Share on other sites More sharing options...
areaweb Posted October 28, 2016 Share Posted October 28, 2016 (edited) Less tech-savvy users can download the latest version of this module: https://github.com/firstred/mpgooglemapsfix/releases and just install it through the back office This module is broken, it doens't use the 'key' GET parameter but instead appends the key to the url like this: Wrong: ?sensor=true&<API_KEY> Correct ?sensor=true&key=<API_KEY> Edited October 28, 2016 by areaweb (see edit history) Link to comment Share on other sites More sharing options...
crochead Posted October 31, 2016 Share Posted October 31, 2016 (edited) Your store is disabled so I can't check it out. Have you seen THIS? I have it back up and running with the ssl on, still can not get this - have gone back over instructions, still having same issue. I did note my code was different to some others but my API is in there. I have restricted the API with the full address including wildcards as instructed. Noted in page console - error code shows my api after the sensor=true®ion=US& but in the actual code it is after /maps/api/js?key= - is this the problem (you have asked if I have seen this - yes and his stores are not working either https://addtocontainer.co.nz/stores, so perhaps something in the Google Maps fix - Store locator is the problem Google Error - js?sensor=true®ion=US&AIzaSyDT1o38qIzgQpL8tAQYWJvlU1h8dhDsbqM:34 Google Maps API error: MissingKeyMapError https://developers.google.com/maps/documentation/javascript/error-messages#missing-key-map-error //maps.google.com/maps/api/js?key=MY_API_IS_HERE&sensor=true®ion='.substr($default_country->iso_code, 0, 2)); Not sure if this is the issue either - https://www.prestashop.com/forums/topic/288409-force-ssl-on-all-pages-google-maps-stops-working-in-storelocator/ Thanks in advance for your assistance Edited October 31, 2016 by crochead (see edit history) Link to comment Share on other sites More sharing options...
crochead Posted November 4, 2016 Share Posted November 4, 2016 Hey all, I was able to get my stores up on the SSL by disabling the module. Front office Features Google Maps fix - Store locator v1.0.0 - by Mijn Presta https://mosquitocoilholder.boycott-big-box.com.au/stores it seemed to be putting the api key in the wrong place as per my previous post Link to comment Share on other sites More sharing options...
Inkkari Posted November 8, 2016 Share Posted November 8, 2016 crochead Thank you so much!!! 1 Link to comment Share on other sites More sharing options...
Mary Montesinos Posted November 15, 2016 Share Posted November 15, 2016 Thanks! Very easy to do Link to comment Share on other sites More sharing options...
prestaAnwender77 Posted November 22, 2016 Share Posted November 22, 2016 hey crochead you link is down ? you can this file upload ? Link to comment Share on other sites More sharing options...
zukkk Posted November 23, 2016 Share Posted November 23, 2016 just use this code: replace this: <script src="http://maps.googleapis.com/maps/api/js"></script> something like this in your contact tpl file with this: <script src="http://maps.googleapis.com/maps/api/js?key=BIzaSyA1gvGcwg6OPMaLsSutIecjkIXrABV3AoF"></script>; where after js?key= here you should put your google api key. https://developers.google.com/maps/documentation/javascript/get-api-key Link to comment Share on other sites More sharing options...
serdib Posted December 2, 2016 Share Posted December 2, 2016 (edited) For everyone! Don't forget to insert your API key also to /controllers/admin/AdminOrdersController.php Around line 340 (see screenshot) This will fix API warnings in Backoffice. And also remove &sensor=false code. Edited December 2, 2016 by serdib (see edit history) 1 Link to comment Share on other sites More sharing options...
Darkforcess Posted December 3, 2016 Share Posted December 3, 2016 Hi, i tried everything you say but it still dont works for me maybe you can help http://winkel.ajlaktechniek.nl/stores thx Ferry Link to comment Share on other sites More sharing options...
Darkforcess Posted December 3, 2016 Share Posted December 3, 2016 Hey it works i did what crochead told us, i deleted the google map fix great work thanx alot ferry Link to comment Share on other sites More sharing options...
tubeman Posted December 13, 2016 Share Posted December 13, 2016 Thanks, this did the trick. Link to comment Share on other sites More sharing options...
banchijojo Posted January 1, 2017 Share Posted January 1, 2017 mdekker - thank you for this. One quick question, well two: one: how do you adjust the map pan, for example mine is zoomed in as far as it can be, for the default I'd like it a little panned out to see more of the roads around my location. two: my map icon is the prestashop penguin, can that be changed? thank you for your help on this, Link to comment Share on other sites More sharing options...
adm666 Posted January 9, 2017 Share Posted January 9, 2017 The complete and ultimate solution I found here. http://blog.belvg.com/how-to-fix-google-maps-api-error-missingkeymaperror-in-prestashop.html Thank him! Link to comment Share on other sites More sharing options...
pierluigi.marucci Posted January 15, 2017 Share Posted January 15, 2017 (edited) Bonjour, j'ai un problème d'affichage google maps. Il semble qu'il s'agit de l'API KEY. Quelqu'un peut m indiquer svp comment charger le codeblock2.txt avec mon code API dans le backoffice de prestashop? En effet j ai bien compris comment créer le api key mais je n'arrive pas à modifier le code source je crois? quand je vais sur inspecter page ou code source de la page, je ne peux pas rajouter le text, aucune modification comment faire? merci Pouvez vous m indiquer comment écrire ce code pas par pas? Comme arriver sur le chemin controllers/admin/AdminOrdersController.php e faire la modification/ecriture? Somewhere around line 289, you'll find the following: codeblock1.txt 219 octets 1642 Nombre de téléchargements With your API key (example: POjjo83h3h379020323Hp7sY9bHB6U), change this into: codeblock2.txt 254 octets 1933 Nombre de téléchargements Edited January 15, 2017 by pierluigi.marucci (see edit history) Link to comment Share on other sites More sharing options...
adm666 Posted January 25, 2017 Share Posted January 25, 2017 BTW, after you update a store with 1-click, you'd have to fix this stuff again. :/ Link to comment Share on other sites More sharing options...
abeee Posted February 26, 2017 Share Posted February 26, 2017 thanks. it really worked! Link to comment Share on other sites More sharing options...
daniel.pontigo Posted March 10, 2017 Share Posted March 10, 2017 Newly detected domains require an API key from now on. That kinda sucks :/ Here's the announcement: http://googlegeodevelopers.blogspot.nl/2016/06/building-for-scale-updates-to-google.html You will now need to visit your Google API Console, request an API key for the Google Maps JavaScript API, and change the file /controllers/front/StoresController.php Somewhere around line 289, you'll find the following: codeblock1.txt With your API key (example: POjjo83h3h379020323Hp7sY9bHB6U), change this into: codeblock2.txt and Google Maps should be working again. Hi: I set the code. but still having the same problem, can you help me please? this is mi code : if (!Configuration::get('PS_STORES_SIMPLIFIED')) { $default_country = new Country((int)Tools::getCountry()); $this->addJS('https://maps.googleapis.com/maps/api/js?key=AIzaSyAlE4X4vPPPLdE69X3xUboAKlyYZGY-Sow'); this is my web site: www.meridaestablecimientos.mx and this is my api credentials: Clave de API AIzaSyAlE4X4vPPPLdE69X3xUboAKlyYZGY-Sow Nombre Restricción de claveLa restricción de claves te permite especificar qué sitios web, direcciones IP o apps pueden usar esta clave. Más información NingunoURL de referencia HTTP (sitios web)Direcciones IP (servidores web, trabajos cron, etc.)Apps de AndroidApps de iOS Aceptar solicitudes de estas URL de referencia HTTP (sitios web) (Opcional) Usa asteriscos como comodines. Si dejas esto en blanco, se aceptarán las solicitudes de cualquier URL de referencia. Asegúrate de agregar URL de referencia antes de usar esta clave en producción. www.meridaestablecimientos.mx I don´t know what I´m doing wrong, please help me! Link to comment Share on other sites More sharing options...
massimomassimo Posted April 8, 2017 Share Posted April 8, 2017 (edited) Hi, now way to get it works! And the link to the module is not working. But I got it work! How: Use the solution above with the .txt files, very precise and for the api don't spend too much time playing around or you will get errors. Just click https://developers.google.com/maps/documentation/javascript/get-api-key and get your key. Before that I did install this module: https://www.prestashop.com/forums/topic/579631-free-module-contact-form-with-google-map-background/ I don't know if this installation add some necessary fix but now works. Edited April 8, 2017 by massimomassimo (see edit history) Link to comment Share on other sites More sharing options...
w3bsolutions Posted June 6, 2017 Share Posted June 6, 2017 Since PS 1.6.1.14 it is possible to enter the API key in Preferences > General So no need for overrides anymore. 1 Link to comment Share on other sites More sharing options...
prestahench Posted June 30, 2017 Share Posted June 30, 2017 Guys, I tried every single solution in this topic and also tried this to include in the cms.tpl of the theme Im using {if $cms->id==10} {literal} <script async defer src="https://maps.googleapis.com/maps/api/js?key=MYKEY"> </script> {/literal} {/if} There's now way for me to show google maps. It shows for a second when the page is loaded and then it goes blank to the classic error of google. In the JS console of course I see the NO API key error. I repeat, I tried ALL the steps listed here. Still no api key error. Also tried to wait five mins after editing the controller, no results. If I use my solution, the code I pasted above, not only I get the no api key error, but I also get the MULTIPLE API keys error TOGETHER! I'm using a module built by me that uses this: https://hpneo.github.io/gmaps/ Google maps was working great in a stage environment till yesterday, today I moved this website to the production domain and this error appears all the time. I'm using the theme Warehouse for prestashop, maybe you know it, I tried to look into it if there's something that overrides my edit in the controller but found nothing. Link to comment Share on other sites More sharing options...
w3bsolutions Posted July 2, 2017 Share Posted July 2, 2017 Guys, I tried every single solution in this topic and also tried this to include in the cms.tpl of the theme Im using {if $cms->id==10} {literal} <script async defer src="https://maps.googleapis.com/maps/api/js?key=MYKEY"> </script> {/literal} {/if} There's now way for me to show google maps. It shows for a second when the page is loaded and then it goes blank to the classic error of google. In the JS console of course I see the NO API key error. I repeat, I tried ALL the steps listed here. Still no api key error. Also tried to wait five mins after editing the controller, no results. If I use my solution, the code I pasted above, not only I get the no api key error, but I also get the MULTIPLE API keys error TOGETHER! I'm using a module built by me that uses this: https://hpneo.github.io/gmaps/ Google maps was working great in a stage environment till yesterday, today I moved this website to the production domain and this error appears all the time. I'm using the theme Warehouse for prestashop, maybe you know it, I tried to look into it if there's something that overrides my edit in the controller but found nothing. Did you add your production domain to the list of accepted domains by that key in Google Console? Link to comment Share on other sites More sharing options...
prestahench Posted July 3, 2017 Share Posted July 3, 2017 Did you add your production domain to the list of accepted domains by that key in Google Console? Actually nope, should I do it? I included google maps in like 15+ wordpress websites by only including the api key and without setting a domain. I'll try this but I doubt that's the issue Link to comment Share on other sites More sharing options...
chirag_0110 Posted July 5, 2017 Share Posted July 5, 2017 Hi Chirag, I managed to find the location for API following an earlier post in this topic. Thanks for your advice. You guys are awesome! Thanks. Link to comment Share on other sites More sharing options...
prestahench Posted July 5, 2017 Share Posted July 5, 2017 Actually nope, should I do it? I included google maps in like 15+ wordpress websites by only including the api key and without setting a domain. I'll try this but I doubt that's the issue I was able to fix my issue in the end thanks to a friend who helped me out. In my case the issue was a conflict between the google api key that was added 2 times in the same page. One module I had, for a contact form, added the api key link (without api key) from google in every page nmw. Link to comment Share on other sites More sharing options...
fibo Posted July 7, 2017 Share Posted July 7, 2017 I've the same problem describe in the first post. I'm using Prestashop 1.16.1.14 and I resolved it adding Google Key in controllers/front/StoreControllers.php Link to comment Share on other sites More sharing options...
biswanath747 Posted September 5, 2017 Share Posted September 5, 2017 Nice thank you so much it is working 100% Link to comment Share on other sites More sharing options...
Didier Bigand Posted September 14, 2017 Share Posted September 14, 2017 (edited) Hi everybody, i've the same problem with any carriers. Google Map is never show.So i've follow this step : 1) Get the API Key :https://console.developers.google.com/apis 2) Active all API required : Google Maps JavaScript API Google Maps Geocoding API Google Maps Geolocation API 3) Change code line 289 to insert my own API Key : /controllers/front/StoresController.php Save & upload on my server.if I understood everything it will be ok tomorrow right ? Thanks for advices.Edit : Not working ! Still show message Key error. Edited September 19, 2017 by Didier Bigand (see edit history) Link to comment Share on other sites More sharing options...
ModaParisNina Posted October 9, 2017 Share Posted October 9, 2017 Beste iedereen, Ik heb de API code toegevoegd, heb Google Maps JavaScript API, Google Maps Geocoding API en Google Maps Geolocation API ingeschakeld. Maar hij doet het nogsteeds niet. Ik heb pretashop versie 1.6.1.11 Groetjes Link to comment Share on other sites More sharing options...
Dmytro Korolkov Posted November 6, 2017 Share Posted November 6, 2017 (edited) Prestashop 1.6.1.17 Editing of /modules/tmgooglemap/tmgooglemap.php 258 line $this->context->controller->addJS('http'.((Configuration::get('PS_SSL_ENABLED') && Configuration::get('PS_SSL_ENABLED_EVERYWHERE')) ? 's' : '').'://maps.google.com/maps/api/js?sensor=true&region='.Tools::substr($default_country->iso_code, 0, 2)); to $this->context->controller->addJS('http'.((Configuration::get('PS_SSL_ENABLED') && Configuration::get('PS_SSL_ENABLED_EVERYWHERE')) ? 's' : '').'://maps.google.com/maps/api/js?key=YOUR_API_KEY&sensor=true®ion='.substr($default_country->iso_code, 0, 2)); helps for me! YOUR_API_KEY = is your key from https://console.developers.google.com/apis/credentials Edited November 7, 2017 by Dmytro Korolkov (see edit history) Link to comment Share on other sites More sharing options...
marcin_jaworski Posted November 23, 2017 Share Posted November 23, 2017 https://belvg.com/blog/how-to-fix-google-maps-api-error-missingkeymaperror-in-prestashop.html Link to comment Share on other sites More sharing options...
odeg Posted September 18, 2018 Share Posted September 18, 2018 If You use Warehouse u need to edit also $apiUrl in customcontactpage.php in module customcontactpage. if((Configuration::get('PS_SSL_ENABLED'))) $apiUrl = 'https://maps-api-ssl.google.com/maps/api/js?key=XXXXx... else $apiUrl = 'http://maps.google.com/maps/api/js?key=XXXXXX... Link to comment Share on other sites More sharing options...
M.shahzad Posted September 29, 2020 Share Posted September 29, 2020 HOW CAN I FIX ERROR OF GOOGLE MAP YOU MAY ALSO CHECK THESE LINK https://www.scottishpro.com/stores ANY BODY SUGGESTS ME HOW CAN I SOLVE IT. Link to comment Share on other sites More sharing options...
nnd.newbie Posted September 29, 2020 Share Posted September 29, 2020 (edited) I see you have added an API key: AIzaSyBqqWw-bThjgnngf4i8twKOHKcoDHRPkgY Log in to: https://console.cloud.google.com and check if API Key has access to: Geocoding API Maps JavaScript API Geolocation API Also in Credentials, click on API key "AIzaSyBqqWw-bThjgnngf4i8twKOHKcoDHRPkgY" and examine "Application restrictions". Change it to "none", wait few minutes and reload webpage. If map works, set restrictions to "HTTP Referrers (web sites)" and "Websites restrictions" to: scottishpro.com/* *.scottishpro.com/* Edited September 29, 2020 by nnd.newbie (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now