PagesEditor::editor method

Auto-assign a page name to gven page

Typically this would be used only if page had no name or if it had a temporary untitled name.

Page will be populated with the name given. This method will not populate names to pages that already have a name, unless the name is "untitled"

Usage

// basic usage
$string = $pages->editor->setupPageName(Page $page);

// usage with all arguments
$string = $pages->editor->setupPageName(Page $page, array $options = []);

Arguments

NameType(s)Description
$pagePage
$options (optional)array

Return value

string

If a name was generated it is returned. If no name was generated blank is returned.


$pages->editor methods and properties

API reference based on ProcessWire core version 3.0.252