Where to insert Google Maps API code in functions.php

0 views
0

I’ve been having some issues since Google requires an API code (which I already have) to display the map on the theme page, but the thing is I’m not sure where and how it should be enqueued.

This is what it looks like on the code:

function sano_footer_scripts() {

//    wp_enqueue_script( 'jquery_1.11.2_min_js',         get_template_directory_uri() . '/js/jquery-1.11.2.min.js','','', true);
//    wp_enqueue_script( 'google_js',                    'https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false','','', true);
//    wp_enqueue_script( 'jquery_autosize_js',           get_template_directory_uri() . '/js/jquery.autosize.js','','', true);
//    wp_enqueue_script( 'jquery_smooth_scroll_min_js',  get_template_directory_uri() . '/js/jquery.smooth-scroll.min.js','','', true);
//    wp_enqueue_script( 'selectivizr_min_js',           get_template_directory_uri() . '/js/selectivizr-min.js','','', true);
//    wp_enqueue_script( 'jquery_watermark_min_js',      get_template_directory_uri() . '/js/jquery.watermark.min.js','','', true);
//    wp_enqueue_script( 'read_more_js',                 get_template_directory_uri() . '/js/read_more.js','','', true);
//    wp_enqueue_script( 'jquery_mixitup_min_js',        get_template_directory_uri() . '/js/jquery.mixitup.min.js','','', true);
//    wp_enqueue_script( 'jquery_magnific_popup_min_js', get_template_directory_uri() . '/js/jquery.magnific-popup.min.js','','', true);
//    wp_enqueue_script( 'jquery_animateNumber_min_js',  get_template_directory_uri() . '/js/jquery.animateNumber.min.js','','', true);
//    wp_enqueue_script( 'select2_min_js',               get_template_directory_uri() . '/js/select2.min.js','','', true);
//    wp_enqueue_script( 'owl_carousel_min_js',          get_template_directory_uri() . '/js/owl.carousel.min.js','','', true);
//    wp_enqueue_script( 'parallax_plugin_min_js',       get_template_directory_uri() . '/js/parallax-plugin.min.js','','', true);
//    wp_enqueue_script( 'jquery_nicescroll_min_js',     get_template_directory_uri() . '/js/jquery.nicescroll.min.js','','', true);
//    wp_enqueue_script( 'jquery_inview_min_js',         get_template_directory_uri() . '/js/jquery.inview.min.js','','', true);
//    wp_enqueue_script( 'jquery_validate_js',           get_template_directory_uri() . '/js/jquery.validate.js','','', true);
//    wp_enqueue_script( 'jquery_hoverdir_js',           get_template_directory_uri() . '/js/jquery.hoverdir.js','','', true);
//wp_enqueue_script( 'map_default_js',               get_template_directory_uri() . '/js/map-default.js','','', true);
//wp_enqueue_script( 'responsiveslides_min_js',      get_template_directory_uri() . '/js/responsiveslides.min.js','','', true);
//wp_enqueue_script( 'jquery_ui_js',                 get_template_directory_uri() . '/js/jquery-ui.js','','', true);
//wp_enqueue_script( 'init_js',                      get_template_directory_uri() . '/js/init.js','','', true);
//wp_enqueue_script( 'respond_src_js',               get_template_directory_uri() . '/js/respond.src.js','','', true);
 }

//add_action( 'wp_enqueue_scripts', 'sano_footer_scripts' );

Can anyone tell me where my API code should be?