Fix book comment handling ... once again

This commit is contained in:
Sébastien Lucas 2013-03-07 10:58:58 +01:00
parent 75862fe24c
commit 02b55687e2

View file

@ -32,7 +32,7 @@ function html2xhtml ($html) {
$doc->loadHTML($html); // Load the HTML
$output = utf8_decode($doc->saveXML($doc->documentElement)); // Transform to an Ansi xml stream
$output = xml2xhtml($output); // Fix the br / hr ...
if (preg_match ("/<html><body>(.*)<\/body><\/html>/", $output, $matches)) {
if (preg_match ("#<html><body>(.*)</body></html>#ms", $output, $matches)) {
$output = $matches [1]; // Remove <html><body>
}
return $output;