diff --git a/Classes/Service/Preview/ContentExtractors/BaseUrlParser.php b/Classes/Service/Preview/ContentExtractors/BaseUrlParser.php new file mode 100644 index 00000000..983548f0 --- /dev/null +++ b/Classes/Service/Preview/ContentExtractors/BaseUrlParser.php @@ -0,0 +1,19 @@ +]*>(.*)<\/body>/is", $content, $matchesBody); + + if ($bodyFound) { + $body = $matchesBody[1]; + + preg_match_all( + '/.*?/mis', + $body, + $indexableContents + ); + + if (is_array($indexableContents[0]) && !empty($indexableContents[0])) { + $body = implode('', $indexableContents[0]); + } + } + + return $this->prepareBody($body); + } + + protected function prepareBody(string $body): string + { + $body = $this->stripTagsContent($body, '