Skip to content

Commit

Permalink
feature 2995: disable DOM parsing warnings
Browse files Browse the repository at this point in the history
git-svn-id: http://piwigo.org/svn/trunk@25787 68402e56-0260-453c-a942-63ccdbb3a9ee
  • Loading branch information
mistic100 committed Dec 4, 2013
1 parent e7b45d1 commit 989d3af
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion include/functions_mail.inc.php
Expand Up @@ -907,9 +907,17 @@ function move_css_to_body($content)
{
include_once(PHPWG_ROOT_PATH.'include/emogrifier.class.php');

// disable DOM warnings
$e_state = libxml_use_internal_errors(true);

$e = new Emogrifier($content);
// $e->preserveStyleTag = true;
return $e->emogrify();
$content = $e->emogrify();

libxml_clear_errors();
libxml_use_internal_errors($e_state);

return $content;
}

/**
Expand Down

0 comments on commit 989d3af

Please sign in to comment.