switch to html2text() instead of strip_tags() when preparing FTS index

This commit is contained in:
Andrew Dolgov
2023-10-21 10:51:24 +03:00
parent 2b61052e87
commit 03e956132d
73 changed files with 27833 additions and 17 deletions

View File

@@ -0,0 +1,16 @@
<?php
/**
* This file is available if you still want to use functions rather than
* autoloading classes.
*/
require_once(__DIR__ . "/src/Html2Text.php");
require_once(__DIR__ . "/src/Html2TextException.php");
function convert_html_to_text($html, $ignore_error = false) {
return Soundasleep\Html2Text::convert($html, $ignore_error);
}
function fix_newlines($text) {
return Soundasleep\Html2Text::fixNewlines($text);
}