messages and such
[glcas.git] / lib / plugins / www.php
index d060677..2c59349 100644 (file)
@@ -51,7 +51,7 @@ function www_basePage($calls)
                www_top();
        }
        
-       echo "</td></tr><tr><td>";
+       echo "</td></tr><tr valign=\"top\"><td>";
        
        // left menu
        if(isset($calls["left_menu_function"])) {
@@ -114,6 +114,19 @@ function www_top()
        }
        
        echo "</tr></table>";
+       if(function_exists("msg_haveMessages")) if(msg_haveMessages()) {
+               echo "<table>";
+               $msgs = msg_getMessages();
+               
+               foreach($msgs as $msg) {
+                       $msgtime = msg_toDate($msg["msgdate"]);
+                       $msgcol = $msg["msgcolour"];
+                       $msgtxt = $msg["msgtext"];
+                       
+                       echo "<tr><td><font color=\"$msgcol\">$msgtime - $msgtxt</font>";
+               }
+               echo "</table>";
+       }
 }
 
 function www_leftmenu()
@@ -136,4 +149,17 @@ function www_pageend()
 {
        echo "</body></html>";
 }
+
+function urlCreate($from)
+{
+       global $MENU_ITEMS, $GLOBAL_BASE_URL;
+
+       $mlink = "$GLOBAL_BASE_URL/".$from;
+       $mlink = preg_replace("/\/[\/]+/", "/", $mlink);
+       
+       return $mlink;
+       
+}
+
+
 ?>
\ No newline at end of file