Documentation

ConfigPage
in package
Uses UtilsProvider

Creates a WordPress backend menu page to configure the cookie banner.

Table of Contents

Constants

ADMIN_BAR_TOP_LEVEL_NODE_ID  = 'rcb-top-node'
CHECKLIST_OVERDUE  = '+1 week'
COMPONENT_ID  = RCB_SLUG . '-component'
TRANSIENT_SERVICES_WITH_EMPTY_PRIVACY_POLICY  = RCB_OPT_PREFIX . '-services-with-empty-privacy-policy'

Methods

admin_menu()  : mixed
Add new menu page.
admin_notices_ad_blocker()  : mixed
Creates an admin notice in the settings page if an ad-blocker got detected.
admin_notices_preinstalled_environment()  : mixed
Creates an admin notice for preinstalled environments.
ensureAdminBarTopLevelNode()  : mixed
Create the top menu admin bar for "Real Cookie Banner" and return the `parent` id so you can add additional drop down menus.
getIconAsSvgBase64()  : mixed
Get the Real Cookie Banner logo as SVG icon in base64 format.
getIconAsSvgSpan()  : mixed
Get the Real Cookie Banner logo as SVG icon in base64 format within a `<span>`.
getPluginConstantPrefix()  : string
Get the prefix of this plugin so composer packages can dynamically build other constant values on it.
getUrl()  : mixed
Get the URL of this page.
instance()  : mixed
New instance.
isVisible()  : mixed
Check if a given page string is this config page or from the current page `pagenow`.
plugin_action_links()  : array<string|int, string>
Show a "Settings" link in plugins list.
render_component_library()  : mixed
Render the content of the menu page.
__construct()  : mixed
C'tor.

Constants

ADMIN_BAR_TOP_LEVEL_NODE_ID

public mixed ADMIN_BAR_TOP_LEVEL_NODE_ID = 'rcb-top-node'

CHECKLIST_OVERDUE

public mixed CHECKLIST_OVERDUE = '+1 week'

COMPONENT_ID

public mixed COMPONENT_ID = RCB_SLUG . '-component'

TRANSIENT_SERVICES_WITH_EMPTY_PRIVACY_POLICY

public mixed TRANSIENT_SERVICES_WITH_EMPTY_PRIVACY_POLICY = RCB_OPT_PREFIX . '-services-with-empty-privacy-policy'

Methods

admin_menu()

Add new menu page.

public admin_menu() : mixed

admin_notices_ad_blocker()

Creates an admin notice in the settings page if an ad-blocker got detected.

public admin_notices_ad_blocker() : mixed

admin_notices_preinstalled_environment()

Creates an admin notice for preinstalled environments.

public admin_notices_preinstalled_environment() : mixed

ensureAdminBarTopLevelNode()

Create the top menu admin bar for "Real Cookie Banner" and return the `parent` id so you can add additional drop down menus.

public ensureAdminBarTopLevelNode() : mixed

getIconAsSvgBase64()

Get the Real Cookie Banner logo as SVG icon in base64 format.

public static getIconAsSvgBase64([string $color = '#9ea3a8' ]) : mixed
Parameters
$color : string = '#9ea3a8'

getIconAsSvgSpan()

Get the Real Cookie Banner logo as SVG icon in base64 format within a `<span>`.

public static getIconAsSvgSpan([string $color = '#9ea3a8' ][, string $additionalStyle = '' ]) : mixed
Parameters
$color : string = '#9ea3a8'
$additionalStyle : string = ''

getPluginConstantPrefix()

Get the prefix of this plugin so composer packages can dynamically build other constant values on it.

public getPluginConstantPrefix() : string
Tags
codeCoverageIgnore

It only returns a string with the constant prefix

Return values
string

getUrl()

Get the URL of this page.

public getUrl() : mixed

instance()

New instance.

public static instance() : mixed

isVisible()

Check if a given page string is this config page or from the current page `pagenow`.

public isVisible([string $hook_suffix = false ]) : mixed
Parameters
$hook_suffix : string = false

The current admin page (admin_enqueue_scripts)

Show a "Settings" link in plugins list.

public plugin_action_links(array<string|int, string> $actions) : array<string|int, string>
Parameters
$actions : array<string|int, string>
Return values
array<string|int, string>

render_component_library()

Render the content of the menu page.

public render_component_library() : mixed

__construct()

C'tor.

private __construct() : mixed

        
On this page

Search results