Skip to content

Instantly share code, notes, and snippets.

@derak-kilgo
Forked from lots0logs/child-functions.php
Created July 10, 2018 20:36
Show Gist options
  • Save derak-kilgo/e5f9ad6a3f4e4c9af9c3d515016e5d01 to your computer and use it in GitHub Desktop.
Save derak-kilgo/e5f9ad6a3f4e4c9af9c3d515016e5d01 to your computer and use it in GitHub Desktop.
WordPress :: Divi Builder :: Disable Google Maps
<?php
/**
* @package Divi_Disable_Maps
* @version 1.0
*/
/*
Plugin Name: Divi Disable Maps
Description: Enable only if you are not using the map module. Fixes "Google Maps JavaScript API warning: NoApiKeys" wanring in the console.
Author: lots0logs
Author URI: https://gist.github.com/lots0logs/67d639070dc54505eef1
Version: 1.0
Text Domain: divi-disable-maps
*/
function divi_disable_maps_et_pb_admin_scripts_styles() {
wp_dequeue_script( 'google-maps-api' );
}
add_action( 'admin_enqueue_scripts', 'divi_disable_maps_et_pb_admin_scripts_styles', 99, 1 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment