From 81721ded5cb9536411bd47cd8494ef62c1ab4b60 Mon Sep 17 00:00:00 2001
From: "Edward Z. Yang" <edwardzyang@thewritingpot.com>
Date: Sun, 10 Sep 2006 22:47:27 +0000
Subject: [PATCH] Disable HTML output when run from cli.

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@405 48356398-32a2-884e-a903-53898d9a118a
---
 configdoc/generate.php | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/configdoc/generate.php b/configdoc/generate.php
index 86106ee2..172002ae 100644
--- a/configdoc/generate.php
+++ b/configdoc/generate.php
@@ -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!
-echo $html_output;
+if (php_sapi_name() != 'cli') {
+    echo $html_output;
+} else {
+    echo 'Files generated successfully.'
+}
 
 ?>
\ No newline at end of file