$this->processor =
$proc;
} public function doctype($name,
$idType = 0,
$id = null,
$quirks = false
) { // This is used solely for setting quirks mode. Currently we don't
// try to preserve the inbound DT. We convert it to HTML5.
$this->quirks =
$quirks;
if ($this->insertMode >
static::IM_INITIAL
) { $this->
parseError('Illegal placement of DOCTYPE tag. Ignoring: ' .
$name);
return;
} $this->insertMode =
static::IM_BEFORE_HTML;
} /**
* Process the start tag.
*
* @todo - XMLNS namespace handling (we need to parse, even if it's not valid)
* - XLink, MathML and SVG namespace handling
* - Omission rules: 8.1.2.4 Optional tags
*
* @param string $name
* @param array $attributes
* @param bool $selfClosing
*
* @return int
*/