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

	$class=$_REQUEST['class'];
	$section=$_REQUEST['section'];
	$chapter=$_REQUEST['chapter'];
	$topic=$_REQUEST['topic'];
	$url=$_REQUEST['url'];
	$date=$_REQUEST['date'];
	$time=$_REQUEST['time'];
	$teacher_id=$_REQUEST['teacher_id'];
    $status = $_REQUEST['status'];
    $zoom_meeting_id = $_REQUEST['zoom_meeting_id'];
    $endtime = $_REQUEST['endtime'];
    $duration = $_REQUEST['duration'];
/*	
	$name=mysql_real_escape_string($name);
	$class=mysql_real_escape_string($class);
	$fname=mysql_real_escape_string($fname);
	$mname=mysql_real_escape_string($mname);
	$mobile=mysql_real_escape_string($mobile);

 */
	 
	 $aryData=array(
		 "class"=>$class,
		 "section"=>$section,
		 "chapter"=>$chapter,
		 "topic"=>$topic,
		 "url"=>$url,
		 "date"=>$date,
		 "time"=>$time,
		 "teacher_id"=>$teacher_id,
         "status"=>$status,
         "zoom_meeting_id" => $zoom_meeting_id,
         "endtime" => $endtime,
         "duration" => $duration
	 );

  		$insert_complain=$db->insertAry("liveclass_meet",$aryData);

  if($insert_complain>0){ $msg="data registered successfully";

  }

	if($msg!="")
	{
		echo json_encode(array('status' => 1, 'msg'=>'Done', "data"=>$msg));
	}
	else
	{
	 	echo json_encode(array('status' => 0, 'msg'=>'data not registerd. Please try again later..!'));
	}
