<?php
	require "../commonincludefiles.php";
   	$objFeedback_que = new feedback_que_masterMgmt();
	$i=0;
	$where = "";	
	/*if($_REQUEST['branch_id']!="")
	{
		$where.=" AND branch_id= '".$_REQUEST['branch_id']."'";
	}
	
	if($_REQUEST['semester_id']!="")
	{
		$where.=" AND semester_id= '".$_REQUEST['semester_id']."'";
	}
	if($_REQUEST['subject_id']!="")
	{
		$where.=" AND subject_id= '".$_REQUEST['subject_id']."'";
	}*/
	
	$rs = $objFeedback_que->getAllRecords($limit,$start,$where,$order_field,$order_type);
	$total = dbRows($rs);
	$QueData = array("count" => $total, "data" => array());
	if(dbRows($rs) > 0){
		while($row = dbArray($rs)){
			$temparray["que_id"] = $row["que_id"];
			//$temparray["branch_id"] = $row["branch_id"];
			//$temparray["semester_id"] = $row["semester_id"];
			//$temparray["subject_id"] = $row["subject_id"];			
			$temparray["question"] = stripcslashes($row["question"]);
			$temparray["ans_a"] = stripcslashes($row["ans_a"]);
			$temparray["ans_b"] = stripcslashes($row["ans_b"]);
			$temparray["ans_c"] = stripcslashes($row["ans_c"]);
			$temparray["ans_d"] = stripcslashes($row["ans_d"]);			
			$QueData["data"][$i] = $temparray;   
			$i++;
		}
	}
	echo json_encode($QueData);	
?>