--- /dev/null
+<?php
+/**
+ * A debug output class for PHP's error_log() command
+ */
+class DebugErrorLogOutput extends BaseFrameworkSystem implements Debugger {
+ /**
+ * Private constructor
+ *
+ * @return void
+ */
+ private function __construct () {
+ // Call parent constructor
+ parent::constructor(__CLASS__);
+
+ // Set description
+ $this->setPartDescr("Debug-Ausgabe in error_log()");
+
+ // Create an unique ID
+ $this->createUniqueID();
+ }
+
+ /**
+ * Creates an instance of this class
+ *
+ * @return $debugInstance The prepared debug instance
+ */
+ public final static function createDebugErrorLogOutput () {
+ // Get a new instance
+ $debugInstance = new DebugErrorLogOutput();
+
+ // Return it
+ return $debugInstance;
+ }
+
+ /**
+ * Outputs the given data without HTML tags
+ *
+ * @param $output The HTML'ed output
+ * @return void
+ */
+ public final function outputStream ($output) {
+ // Split multiple lines into and array to put them out line-by-line
+ $errorLines = explode("\n", $output);
+ foreach ($errorLines as $err) {
+ $err = trim($err);
+ // Log only none-empty lines
+ if (!empty($err)) {
+ // Log this line
+ error_log(html_entity_decode(strip_tags($err)), 0);
+ }
+ }
+ }
+}
+
+// [EOF]
+?>