<?php
include("../../db.php"); 
header("Access-Control-Allow-Origin: * ");

$data=array();

    $allmodules = $db->getRows("select * from student_control");
    if(count($allmodules)>0 && is_array($allmodules)){
        foreach($allmodules as $module){
            $data []= $module[module_name];
        }
    }


	if(is_array($data) && count($data)>0)
	{
		echo json_encode(array('status' => 1, 'msg'=>'Record found Successfully..!', "data"=>$data));    
			
	}else
	{		
	 	echo json_encode(array('status' => 0, 'msg'=>'No record Found..!'));
	}