<?php

	class UtilitiesManager
	{
		var $username;     //Username given on sign-up

		function UtilitiesManager(){

		}
		//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
		
		function getManagersMessage(){
			global $database;
		
			$query = "
				SELECT 
					IndexID,
					Message,
					IsActive
				FROM 
					".TBLMANAGERSMESSAGE." 
				WHERE 	
					IndexID = (SELECT MAX(IndexID) FROM ".TBLMANAGERSMESSAGE.")";
				
			$result = $database->query($query);
			$numRows = mysql_numrows($result);
			
			if(!$result || $numRows < 0){
				if(DEBUG == true){
					printf("Error in query: %s", $query);
				}
			}
			
			for($i=0; $i<$numRows; $i++){
				$Message = mysql_result($result, $i, "Message");
				$IsActive = mysql_result($result, $i, "IsActive");
				$IndexID = mysql_result($result, $i, "IndexID");

				echo "
					<div class='message info'>
                            <b>MANAGERS NOTE:</b> 
                            <p> 
                                $Message
                            </p> 
                        </div>
				";
			}//End for loop through result set
		}//end Get Issue Listing
		//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
		
	};

	$manager = new UtilitiesManager;
?>