WireMarkupRegions::getTagInfo()
Given HTML tag like “<div id='foo' class='bar baz'>” return associative array of info about it
Returned info includes:
name(string): Tag nameid(string): Value of id attributepwid(string): PW region ID from 'pw-id' or 'data-pw-id', or if not present, then same as 'id'action(string): Action for this region, without “pw-” prefix.actionTarget(string): Target id for the action, if applicable.actionType(string): "class" if action specified as class name, "attr" if specified as a pw- or data-pw attribute.classes(array): Array of class names (from class attribute).attrs(array): Associative array of all attributes, all values are strings.attrStr(string): All attributes in a stringtag(string): The entire tag as givenclose(string): The HTML string that would close this tag
Usage
$array = $wireMarkupRegions->getTagInfo(string $tag);Arguments
| Name | Type(s) | Description |
|---|---|---|
$tag | string | Must be a tag in format “ |
Return value
array
WireMarkupRegions methods and properties
API reference based on ProcessWire core version 3.0.268