Documentation

Namespaces

Barn2
WPTRT

Interfaces, Classes and Traits

Html_Table_Cell
Represents a cell in a <code>Html_Table_Row</code>.
Html_Table_Row
Represents a row in a <code>Html_Data_Table</code>.
Html_Data_Table
Represents a HTML table. This class allows you to build a table by sequentially adding headings, rows, data, etc, and then outputting to either HTML, and array or JSON.
WC_Settings_Additional_Field_Types
Additional field types for WooCommerce settings pages.
WC_Barn2_Plugin_Promo
Provides functions to add the plugin promo to the plugin settings page in the WordPress admin.
WP_Scoped_Hooks
Allows a temporary hook environment to be created for a given timeframe (i.e. scope), where any hooks added or removed will be recognised only during the specified scope. After the given scope, the original WordPress hook environment is restored to its previous state.
WP_Settings_API_Helper
Helper functions for the WordPress Settings API.

Table of Contents

b2_format_html_attributes()  : string
Formats an array of attributes into a string to be used inside a HTML tag.
edd_hidden_callback()  : mixed
edd_barn2_license_callback()  : mixed
dlp_get_doc_library()  : string
Retrieves a post table for the specified args. The arg names are the same as those used in the shortcode and Table_Args, as well as the addtional DLP args.
dlp_the_doc_library()  : mixed
Outputs a post table for the specified args. The arg names are the same as those used in the shortcode and Table_Args, as well as the addtional DLP args.
dlp_get_document()  : Document|false
Get a document

Functions

b2_format_html_attributes()

Formats an array of attributes into a string to be used inside a HTML tag.

b2_format_html_attributes(array<string|int, mixed> $atts) : string

The first attribute will contain a single space before it.

E.g. b2_format_html_attributes( array( 'data-thing' => 'foo', 'class' = 'test' ) )

would give this string:

' data-thing="foo" class="test"'

Parameters
$atts : array<string|int, mixed>

The attributes to format

Return values
string

The attribute string

edd_hidden_callback()

edd_hidden_callback(mixed $args) : mixed
Parameters
$args : mixed
Return values
mixed

edd_barn2_license_callback()

edd_barn2_license_callback(mixed $args) : mixed
Parameters
$args : mixed
Return values
mixed

dlp_get_doc_library()

Retrieves a post table for the specified args. The arg names are the same as those used in the shortcode and Table_Args, as well as the addtional DLP args.

dlp_get_doc_library([array<string|int, mixed> $args = [] ]) : string
Parameters
$args : array<string|int, mixed> = []

The table args.

Tags
see
The

options documentation or See Table_Args::$default_args for the list of supported args.

Return values
string

The data table as a HTML string.

dlp_the_doc_library()

Outputs a post table for the specified args. The arg names are the same as those used in the shortcode and Table_Args, as well as the addtional DLP args.

dlp_the_doc_library([array<string|int, mixed> $args = [] ]) : mixed
Parameters
$args : array<string|int, mixed> = []

The table args.

Tags
see
The

options documentation or See Table_Args::$default_args for the list of supported args.

Return values
mixed

dlp_get_document()

Get a document

dlp_get_document(int $id) : Document|false
Parameters
$id : int

Document ID

Return values
Document|false

Search results