Commit 27a16092 authored by Chenu Denis's avatar Chenu Denis

[fix] Issue with some HTML

parent ab872b11
......@@ -6,7 +6,7 @@
*
* @author Artem Russakovskii
* @author Denis Chenu
* @version 0.5.0
* @version 0.5.1
* @link http://beerpla.net
* @link http://www.php.net/manual/en/class.domdocument.php
* @license MIT
......@@ -71,7 +71,7 @@ class SmartDOMDocument extends \DOMDocument {
* @return string
*/
public function saveHTMLExact() {
$content = preg_replace(array("/^\<\!DOCTYPE.*?<html><body>/si",
$content = preg_replace(array("/^\<\!DOCTYPE.*?<html>.*?<body>/si",
"!</body></html>$!si"),
"",
$this->saveHTML());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment