add log class
[phinde.git] / src / phinde / Log.php
diff --git a/src/phinde/Log.php b/src/phinde/Log.php
new file mode 100644 (file)
index 0000000..2369a2b
--- /dev/null
@@ -0,0 +1,23 @@
+<?php
+namespace phinde;
+
+class Log
+{
+    public static function error($msg)
+    {
+        static::log($msg);
+    }
+
+    public static function info($msg)
+    {
+        if ($GLOBALS['phinde']['debug']) {
+            static::log($msg);
+        }
+    }
+
+    public static function log($msg)
+    {
+        echo $msg . "\n";
+    }
+}
+?>