class Coder

Methods

bool
checkConsistentHtml(string $html)

Determine whether an HTML snippet remains consistent (through an decode/encode loop).

string
recode(string $html)

Parse an HTML snippet and re-encode is as HTML.

string
encode(phpQueryObject $doc)

Encode a phpQueryObject as HTML.

cleanup($html)

No description

cleanupAttribute($matches)

No description

Details

at line 16
bool checkConsistentHtml(string $html)

Determine whether an HTML snippet remains consistent (through an decode/encode loop).

Note: Variations in whitespace are permitted.

Parameters

string $html

Return Value

bool

at line 41
string recode(string $html)

Parse an HTML snippet and re-encode is as HTML.

This is useful for detecting cases where the parser or encoder have quirks/bugs.

Parameters

string $html

Return Value

string

at line 53
string encode(phpQueryObject $doc)

Encode a phpQueryObject as HTML.

Parameters

phpQueryObject $doc

Return Value

string HTML

at line 58
protected cleanup($html)

Parameters

$html

at line 64
protected cleanupAttribute($matches)

Parameters

$matches