<?php 
session_start();
include 'dbc.php';
$userid=$_SESSION["userid"];
$remarks=$_POST["remarks"];
$bname=$_POST["bname"];
$accno=$_POST["accno"];
date_default_timezone_set("Asia/Karachi");
$today=date("Y-m-d");
$month = date("m",strtotime($today));
		$year = date("Y",strtotime($today));
		 $month_name = date("F", mktime(0, 0, 0, $month, 10));
		 $my=$month_name . " " . $year;

$sql = "Insert into studentcomplain (id,notice,bname,accno,status,user_id,date) values (null,'$remarks','$bname','$accno','Open','$userid','$today')";
$conn->query($sql);
//mysql_query($sql) or die("Error : " . mysql_error());



header("location:Student_Teacher_Complain.php");

/*$sql="Select * from agents where userid='$user_id'";
$data=mysql_query($sql) or die ("Error:" . mysql_error());
$userdata=mysql_fetch_array($data);
$email=$userdata["e_mail"];
mail($email . ",info@lalburj.com","Candidate Information","Candidate Data Posted Successfully","Passport No:" . $app_pp_no . " of " . $app_name . "Has been Posted Successfully By:" . $_SESSION["userid"]);*/
?>
