Class GoogleMapsAPILoader
This class handles loading the Google Maps API and the conditional settings associated with that (load API conditions, exclude pages, etc.)
Deprecated: This class will be merged into GoogleLoader, the API conditionality mechanisms will be abstracted to APILoader for use with OpenLayers
Located at class.google-maps-api-loader.php
public
|
|
protected
array
|
|
public
|
|
public
|
#
enqueueGoogleMaps( )
This function will enqueue the Google Maps API, if the conditions to include it are met. Otherwise, this function will do nothing. |
public
boolean
|
#
isPageIncluded( integer $page_id )
Checks whether the specified page ID has been explicitly included in the plugin settings |
public
boolean
|
#
isPageExcluded( integer $page_id )
Checks whether the specified page ID has been explicitly excluded in the plugin settings |
public
boolean
|
#
isIncludeAllowed( string & $status = null )
Checks if including the Google API is allowed, based on all the relevant settings. |
public
string
|
#
preventOtherGoogleMapsTag( string $tag, string $handle, string $src )
This function hooks into script_loader_tag. If any other plugin or the theme has enqueued a script containing "maps.google", an empty string will be returned, preventing that script loader tag from being rendered. Only the script with the handle wpgmza_api_call will be allowed through. This can be bound using the "prevent other plugins and theme loading maps API" setting. |
public
string
|
#
getSettingsHTML( )
Gets the HTML for the settings panel for this module, which appears in the general settings tab. |
string |
REMOVE_API_CHECKED
|
#
'REMOVE_API_CHECKED'
|
string |
USER_CONSENT_NOT_GIVEN
|
#
'USER_CONSENT_NOT_GIVEN'
|
string |
ENGINE_NOT_GOOGLE_MAPS
|
#
'ENGINE_NOT_GOOGLE_MAPS'
|
string |
PAGE_EXPLICITLY_INCLUDED
|
#
'PAGE_EXPLICITLY_INCLUDED'
|
string |
PAGE_EXPLICITLY_EXCLUDED
|
#
'PAGE_EXPLICITLY_EXCLUDED'
|
string |
NEVER_LOAD_API_SELECTED
|
#
'NEVER_LOAD_API_SELECTED'
|
string |
ONLY_LOAD_FRONT_END_SELECTED
|
#
'ONLY_LOAD_FRONT_END_SELECTED'
|
string |
ONLY_LOAD_BACK_END_SELECTED
|
#
'ONLY_LOAD_BACK_END_SELECTED'
|
string |
ENQUEUED
|
#
'ENQUEUED'
|