0
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-01-03 05:11:52 +00:00

Disable HTML output when run from cli.

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@405 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang 2006-09-10 22:47:27 +00:00
parent 371fb7c3d2
commit 81721ded5c

View File

@ -143,6 +143,10 @@ if (class_exists('Tidy')) {
file_put_contents("$xsl_stylesheet_name.html", $html_output);
// output so you can see the fruits of your work!
if (php_sapi_name() != 'cli') {
echo $html_output;
} else {
echo 'Files generated successfully.'
}
?>