messages and such
authorpaulr <me@pjr.cc>
Wed, 20 Apr 2011 18:24:29 +0000 (04:24 +1000)
committerpaulr <me@pjr.cc>
Wed, 20 Apr 2011 18:24:29 +0000 (04:24 +1000)
lib/plugins/messages.php
lib/plugins/www.php

index 557e6f6..d7a268f 100644 (file)
@@ -17,9 +17,9 @@ function msg_getMessages($acked = false)
        return $data;
 }
 
-function msg_toDate()
+function msg_toDate($time)
 {
-       
+       return strftime("%c", $time);
 }
 
 function msg_addMessage($colour, $message)
index ab6bff9..2c59349 100644 (file)
@@ -119,9 +119,9 @@ function www_top()
                $msgs = msg_getMessages();
                
                foreach($msgs as $msg) {
-                       $msgtime = msg_toDate($msg["time"]);
-                       $msgcol = $msg["colour"];
-                       $msgtxt = $msg["text"];
+                       $msgtime = msg_toDate($msg["msgdate"]);
+                       $msgcol = $msg["msgcolour"];
+                       $msgtxt = $msg["msgtext"];
                        
                        echo "<tr><td><font color=\"$msgcol\">$msgtime - $msgtxt</font>";
                }