Store Locator Plus®

MySLP_Option_Modifier
in package

SLP Option Modifier

Used by this MySLP Dashboard Base Class on as well as the REST API handler.

TODO: Elminate new MySLP_Option_Modifer -- make this a singleton On a single call to Generate Embed on a test server the constructor was called 8x on a single page load.

Table of Contents

Properties

$cache  : mixed
$slplus  : mixed

Methods

__construct()  : mixed
Standard constructor so we can easily extend a base class object later if desired.
modify_smart_options()  : mixed
Modify Smart Options
set_google_geocode_key()  : string
Use main site to override google_geocode_key
set_google_server_key()  : string
Use main site to override google_server_key
set_theme()  : string
Set the Plugin Style to 'a_style_gallery' since we only used SLP hosted styling.
get_override_for_setting()  : mixed
Get override for SLP setting from main site settings.
get_setting_from_main_site()  : mixed
Get the named SLP option from the main site.

Properties

Methods

__construct()

Standard constructor so we can easily extend a base class object later if desired.

public __construct() : mixed

set_google_geocode_key()

Use main site to override google_geocode_key

public set_google_geocode_key(string $value) : string
Parameters
$value : string
Return values
string

set_google_server_key()

Use main site to override google_server_key

public set_google_server_key(string $value) : string
Parameters
$value : string
Return values
string

set_theme()

Set the Plugin Style to 'a_style_gallery' since we only used SLP hosted styling.

public set_theme(string $unused) : string
Parameters
$unused : string

The value SLP wants to use

Return values
string

get_override_for_setting()

Get override for SLP setting from main site settings.

private get_override_for_setting(string $key, mixed $value) : mixed
Parameters
$key : string
$value : mixed

get_setting_from_main_site()

Get the named SLP option from the main site.

private get_setting_from_main_site(string $key, mixed $default) : mixed
Parameters
$key : string
$default : mixed
Return values
mixed

returns default if there is no setting in the serialized SLP array.


        
On this page

Search results