Helper
in package
Content helper functionality
Tags
Table of Contents
Properties
- $instances : array<string|int, object>
- The array of instances of this class and sub-classes.
- $settings : Settings
- The instance of the Settings class.
Methods
- get_instance() : object
- Creates and/or returns the instance of this class.
- render_hero_image() : void
- Render the page hero image.
- strip_whitespace() : string
- Return the input HTML string, stripped of newlines, tabs, repeated, trailing and leading whitespace.
- __construct() : void
- Initialise the class.
Properties
$instances
The array of instances of this class and sub-classes.
protected
static array<string|int, object>
$instances
= array()
Tags
$settings
The instance of the Settings class.
protected
Settings
$settings
Tags
Methods
get_instance()
Creates and/or returns the instance of this class.
public
static get_instance() : object
Tags
Return values
object —The instance of this class.
render_hero_image()
Render the page hero image.
public
render_hero_image() : void
Tags
strip_whitespace()
Return the input HTML string, stripped of newlines, tabs, repeated, trailing and leading whitespace.
public
strip_whitespace(string $html_string) : string
Parameters
- $html_string : string
-
The string to strip.
Tags
Return values
string —The stripped string
__construct()
Initialise the class.
protected
__construct() : void