BuddyClients Docs

Popup
in package

Generates the popup structure.

Creates a popup where content will be inserted for help links.

Tags
since
0.1.0

Table of Contents

Properties

$content  : string
The popup content.

Methods

__construct()  : mixed
Constructor method.
build()  : mixed
Outputs popup.
format_content()  : mixed
Formats content for popup.
get_instance()  : Popup
Returns the single instance of the class.
link()  : mixed
Outputs popup link.
output()  : mixed
Manually outputs a popup.
update_content()  : mixed
Updates the content of the popup.

Properties

$content

The popup content.

public string $content

Methods

__construct()

Constructor method.

public __construct() : mixed
Tags
since
0.1.0

build()

Outputs popup.

public build() : mixed
Tags
since
0.1.0

format_content()

Formats content for popup.

public static format_content([int $post_id = null ][, string $url = null ][, string $raw_content = null ]) : mixed
Parameters
$post_id : int = null

The ID of the post.

$url : string = null

The url of the post or page whose content to fetch.

$raw_content : string = null

Raw content to be used directly.

Tags
since
0.1.0

get_instance()

Returns the single instance of the class.

public static get_instance() : Popup
Return values
Popup

The single instance of the class.

Outputs popup link.

public static link([int $post_id = null ][, string $link_text = null ][, string $url = null ][, string $raw_content = null ]) : mixed
Parameters
$post_id : int = null

The ID of the post from which to retrieve the content.

$link_text : string = null

Optional. The text to display. Defaults to ? icon.

$url : string = null

Optional. The full url of the page to display.

$raw_content : string = null

Optional. Raw content to be used directly.

Tags
since
0.1.0

output()

Manually outputs a popup.

public output(mixed $content) : mixed
Parameters
$content : mixed
Tags
since
1.0.20

update_content()

Updates the content of the popup.

public update_content(string $new_content) : mixed
Parameters
$new_content : string

The new content to be displayed in the popup.


        
On this page

Search results