1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-18 04:12:00 +02:00

Tweak last parser commit and added getTags() test.

This commit is contained in:
Cameron
2020-12-14 11:18:12 -08:00
parent 2a31f831a9
commit c258b856f2
3 changed files with 33 additions and 11 deletions

View File

@@ -3898,7 +3898,7 @@ class e_parser
*/
public function __construct()
{
$this->domObj = new DOMDocument('1.0', 'utf-8');
$this->init();
$this->compileAttributeDefaults();
@@ -5544,7 +5544,7 @@ return;
$html = '<body>'.$html.'</body>';
}
$this->domObj = $doc = new DOMDocument('1.0', 'utf-8');
if($this->scriptAccess === false)
{
@@ -5569,7 +5569,7 @@ return;
// $fragment->appendXML($html);
// $doc->appendChild($fragment);
// $doc->encoding = 'utf-8';
$doc = $this->domObj;
$opts = defined('LIBXML_HTML_NOIMPLIED') ? LIBXML_HTML_NOIMPLIED | LIBXML_HTML_NODEFDTD : 0;
$doc->loadHTML($html, $opts);