<?php 

/**
 * This is general file which contains
 * connection file, common function file, etc.,
 *
 * PHP version 5
 *
 * @category Admin_Tool
 * @package  Admin_Tool
 * @author   Aum Infosys <admin@auminfosys.com>
 * @license  ACE
 * @version  CVS:1.0.1
 * @link     http://auminfosys.com/
 * @filesource
 */
 
/**
 * This is general file which contains
 * connection file, common function file, etc.,
 *
 */

require "../commonincludefiles.php";

$qry = "SELECT * FROM lms_yearmaster";

//print_r($yearData);
$result = dbQuery($qry);

$total = dbRows($result);
$i=0;
$yearData = array("count" => $total, "rows1" => array());
if(dbRows($result) > 0){
	$temparray = array();
	while($row = dbArray($result)){
		$temparray["year_id"]  = $row["year_id"];
		$temparray["year_name"]   = $row["year_name"];
		$temparray["year_active"]   = $row["year_active"];
		$yearData["rows1"][$i] = $temparray;   
		$i++;
	}										
}	
//print_r($yearData);			   		 
echo json_encode($yearData);	

?>