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

    $date=$_POST['date'];
	$time=$_POST['time'];
	$class=$_POST['class'];
	$section=$_POST['section'];
	$subject=$_POST['subject'];
	$url=$_POST['url'];
	$stat = $_POST['status'];
	$teacher_id=$_POST['teacher_id'];

    $status = 0;
    $msg    = '';
	
	$aryData = array(
	    "date"    => $date,
	    "time"    => $time,
	    "class"   => $class,
	    "section" => $section,
	    "subject" => $subject,
	    "url"     => $url,
	    "status"  => $stat,
	    "teacher_id"   => $teacher_id,
	    );


	$sql = $db->insertAry("liveclass_list", $aryData );

    if ($sql > 0) {
        $status = 1;
        $msg="Data saved successfully.";
    }

	echo json_encode(array('status' => $status, 'msg'=>$msg));

