class UnsafeTemplateException extends RuntimeException

Properties

protected DOMNode $node

Methods

__construct(string $msg, DOMNode $node)

No description

getNode()

Return the node that has caused this exception

string
highlightNode(string $prepend = '<span style="background-color:#ff0">', string $append = '</span>')

Highlight the source of the template that has caused this exception, with the node highlighted

void
setNode(DOMNode $node)

Change the node associated with this exception

Details

at line 25
__construct(string $msg, DOMNode $node)

No description

Parameters

string $msg

Exception message

DOMNode $node

The node that is responsible for this exception

at line 36
DOMNode getNode()

Return the node that has caused this exception

Return Value

DOMNode

at line 48
string highlightNode(string $prepend = '<span style="background-color:#ff0">', string $append = '</span>')

Highlight the source of the template that has caused this exception, with the node highlighted

Parameters

string $prepend

HTML to prepend

string $append

HTML to append

Return Value

string

Template's source, as HTML

at line 59
void setNode(DOMNode $node)

Change the node associated with this exception

Parameters

DOMNode $node

Return Value

void