Google Maps on the MGame Theme

Latest Reply from Grace at 2016-07-29 08:37:54
I recently purchased this theme (MGame) and I cannot get google maps to work on the contact form or on any page for that matter. I have looked at other questions but none answer the question.


Unfortunately, I have no access to your website and can not check this issue. Could you clarify whether you try to get and add a Google Maps API key to the theme or not?
No I did not add an API as it did not say I needed to add one. I just loaded the contact form and configured it for my home address to see if working properly.

When it didn't work I just created a page and used the google map shortcut code in the page shortcuts to see if it would work and it didn't.


In this case, try to add a Google Maps API key, this should solve the issue. To do it you need to follow the next steps:

1. Get a Google Maps API key. If you do not know how to do this you can read the next article:

2. Open the functions.php file in the following directory:

3. Find the next part of code:
wp_register_script( 'googlemaps', '', array( 'jquery' ), '3' );

4. And replace it with the next one:
wp_register_script( 'googlemaps', '', array( 'jquery' ), '3' );

You need to use your key instead of the YOUR_API_KEY words.
function smt_register_scripts() {

wp_enqueue_style( 'index', get_template_directory_uri().'/css/index.css' );
wp_enqueue_style( 'style', get_stylesheet_uri() );
wp_enqueue_script( 'jquery' );
wp_register_script( 'googlemaps', '', array( 'jquery' ), '3' );
wp_enqueue_script( 'googlemaps' );
I have added this to the funcations.php as advised but still no luck in getting it to show on the contact form.

If you go to you can see the contact us form.

Please advise.


Since this solution did not help this issue can be caused by the latest update of the Google Maps. Unfortunately, in this case, the only thing we can recommend to you is contact the Google support.

Leave a reply

Add codeAdd image