SLP_UI_Shortcode
extends SLP_Base_Object
in package
AbstractYes
Class SLP_UI_Shortcode
Table of Contents
Constants
- shortcode = 'slp_ui'
Properties
- $ajax_response : array<string|int, mixed>
- $responses : array<string|int, mixed>
- $ajax_response : mixed
- $autoload_shortcode : mixed
- $responses : mixed
Methods
- __construct() : mixed
- SLP_Base_Object constructor.
- activate() : mixed
- Activate the shortcode processing.
- clear_ajax_response() : mixed
- Clear AJAX response.
- get_instance() : SLPlus_BaseClass_Object
- Return an instance of the object which is also registered to the slplus global less the SLP_ part.
- initialize() : mixed
- Do at startup.
- set_properties() : mixed
- Set our properties.
- process() : string
- Process the shortcode into a string output.
- set_ajax_response() : mixed
- Get location data is it would come back to JS via AJAX handler.
Constants
shortcode
public
mixed
shortcode
= 'slp_ui'
Properties
$ajax_response read-only
public
array<string|int, mixed>
$ajax_response
The current location data being processed as it would come back from an AJAX request
$responses read-only
public
array<string|int, mixed>
$responses
An array of ajax repsonses with the key = location ID, prevents multiple requests for the same location data. Serves as a memory cache.
$ajax_response
protected
mixed
$ajax_response
$autoload_shortcode
protected
mixed
$autoload_shortcode
= \true
$responses
protected
mixed
$responses
Methods
__construct()
SLP_Base_Object constructor.
public
__construct([array<string|int, mixed> $options = array() ]) : mixed
Parameters
- $options : array<string|int, mixed> = array()
activate()
Activate the shortcode processing.
public
final activate() : mixed
clear_ajax_response()
Clear AJAX response.
public
final clear_ajax_response() : mixed
get_instance()
Return an instance of the object which is also registered to the slplus global less the SLP_ part.
public
static get_instance([mixed $options = array() ]) : SLPlus_BaseClass_Object
Parameters
- $options : mixed = array()
-
object init params
Return values
SLPlus_BaseClass_Objectinitialize()
Do at startup.
public
final initialize() : mixed
set_properties()
Set our properties.
public
set_properties([array<string|int, mixed> $options = array() ]) : mixed
Parameters
- $options : array<string|int, mixed> = array()
process()
Process the shortcode into a string output.
protected
process(array<string|int, mixed> $attributes, string $content, string $tag) : string
EXTEND THIS IN YOUR CLASS.
Parameters
- $attributes : array<string|int, mixed>
- $content : string
- $tag : string
Return values
stringset_ajax_response()
Get location data is it would come back to JS via AJAX handler.
protected
final set_ajax_response() : mixed