PagesEditor::editor method

Is the given page deleteable from the API?

Note: this does not account for user permission checking. It only checks if the page is in a state to be deleteable via the API.

Usage

// basic usage
$bool = $pages->editor->isDeleteable(Page $page);

// usage with all arguments
$bool = $pages->editor->isDeleteable(Page $page, bool $throw = false);

Arguments

NameType(s)Description
$pagePage
$throw (optional)bool

Throw WireException with additional details?

Return value

bool

True if deleteable, False if not

Exceptions

Method can throw exceptions on error:

  • WireException - If requested to do so via $throw argument


$pages->editor methods and properties

API reference based on ProcessWire core version 3.0.252