pfeifferNet

Tools
in package

Defines the admin page for pfeifferNet tools.

  • This page will contain the individual tools for managing pfeifferNet sites.
Tags
since
5.8.0
since
5.11.0

Deprecated global singleton.

since
6.0.0

Fix text domain loading too early error.

uses
HTTP_Handler
uses
Progress_Indicator

Table of Contents

Constants

CAPABILITY  = 'edit_others_posts'
The user capability required to see the tools menu item.
PAGE_SLUG  = 'pnet-tools'
The tools menu page slug.
TOOLS_CONTAINER  = 'tools.php'
Tools container partial.

Properties

$default_tabs  : array<string|int, mixed>
The set of default tabs to show on tools page.
$http_handler  : HTTP_Handler
The instance of the HTTP_Handler class.
$instances  : array<string|int, object>
The array of instances of this class and sub-classes.
$page_hook  : string
The page hook.
$progress_container  : string
The progress indicator container markup.
$tools_container  : string
Fully qualified path to the tools container partial.

Methods

add_tools_menu()  : void
Add entry to tools menu.
get_instance()  : object
Creates and/or returns the instance of this class.
render()  : void
Render the tools page.
__construct()  : void
Initialise the class.
enqueue_assets()  : void
Enqueue the CSS and JavaScript for the tools.
get_inline_script()  : string
Get the inline javascript.

Constants

CAPABILITY

The user capability required to see the tools menu item.

protected string CAPABILITY = 'edit_others_posts'
Tags
since
5.10.0

PAGE_SLUG

The tools menu page slug.

protected string PAGE_SLUG = 'pnet-tools'
Tags
since
5.3.0

TOOLS_CONTAINER

Tools container partial.

protected string TOOLS_CONTAINER = 'tools.php'
Tags
since
5.3.0

Properties

$default_tabs

The set of default tabs to show on tools page.

protected array<string|int, mixed> $default_tabs = array()
  • These are key-value pairs.
  • The key is the tab slug. The value is the display name for the tab.
Tags
since
5.11.0

$instances

The array of instances of this class and sub-classes.

protected static array<string|int, object> $instances = array()
Tags
since
5.11.0

$page_hook

The page hook.

protected string $page_hook = ''
Tags
since
1.0.0

$progress_container

The progress indicator container markup.

protected string $progress_container = ''
Tags
since
6.0.0

$tools_container

Fully qualified path to the tools container partial.

protected string $tools_container = ''
Tags
since
1.0.0

Methods

get_instance()

Creates and/or returns the instance of this class.

public static get_instance() : object
Tags
since
5.11.0
Return values
object

The instance of this class.

render()

Render the tools page.

public render() : void
  • Enqueue javascript.
  • Set variables for the partial.
Tags
since
1.0.0
since
5.8.0

Enqueue javascript here, rather than on admin hook.

uses
HTTP_Handler::get_get_vars()
uses
get_asset_url()

enqueue_assets()

Enqueue the CSS and JavaScript for the tools.

protected enqueue_assets() : void
Tags
since
1.0.0
since
6.0.0

Deprecated use of common form stylesheet.

get_inline_script()

Get the inline javascript.

protected get_inline_script() : string
Tags
since
5.8.0
since
6.4.0

Return the inline javascript.

Return values
string

The inline javascript.


        
On this page

Search results