guifi / docker-drupal-guifi

Docker images for Drupal with drupal-guifi module enabled
2 stars 4 forks source link

missing google API key for maps #8

Closed ghost closed 7 years ago

ghost commented 7 years ago

as seen in SAX 2017, when you go to maps, an API key is required for google maps

studi7 commented 7 years ago

Hi, I was reading the docs of get api key on google maps API and found this tip: During development and testing, you can register a project for testing purposes in the Google API Console and use a generic, unrestricted API key. read more I have tried a new unrestricted key into guifi-dev environtment and it works.

in the file sites/all/modules/guifi/guifi_includes.inc.php replace line 2163 by this: drupal_set_html_head('<script src="https://maps.google.com/maps/api/js?sensor=false&libraries=places&v=3.22&key=YOUR_API_KEY' .

ghost commented 7 years ago

Great @studi7 !

I would like to see you doing the pull request and committing on that :D

If you need help ask here or via chat.

You have to use perl search & replace regular expression in drupal-entry.pl

rgf1042 commented 7 years ago

Great job! I'll try to make an script for replacing old api key with this you supplied.

studi7 commented 7 years ago

Ok, I will try too. So I'll take my first steps in regex perl ;)

rgf1042 commented 7 years ago

Perfect! :D I got an API From Google, now I'll replace manually the line for testing it.

rgf1042 commented 7 years ago

Solved!