From fae43d54e59eb4c9d7aa668956a2d2d51226e5ff Mon Sep 17 00:00:00 2001 From: yggverse Date: Fri, 22 Mar 2024 19:11:27 +0200 Subject: [PATCH] enable xhtml parser --- src/cli/document/crawl.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/cli/document/crawl.php b/src/cli/document/crawl.php index 9989b95..92a1d56 100644 --- a/src/cli/document/crawl.php +++ b/src/cli/document/crawl.php @@ -231,8 +231,13 @@ foreach($index->search('') } else continue; // DOM crawler - if (false !== stripos($type, 'text/html')) - { + if ( + false !== stripos($type, 'text/html') + || + false !== stripos($type, 'text/xhtml') + || + false !== stripos($type, 'application/xhtml') + ) { $crawler = new Symfony\Component\DomCrawler\Crawler(); $crawler->addHtmlContent( $response