<?php
mysql_connect('localhost','admission2014','admission2014sgvu');
mysql_select_db("sgvuadmission");
?>

<table width="4000" cellpadding="0" cellspacing="0" border="1">
<tr><td>S.No.</td><td>ref id</td><td>course name</td><td>sid</td><td>Password</td><td>Entrance Exam</td><td>rank</td><td>roll</td><td>qualifying exam</td><td>res_declared_date</td><td>enrollment no</td><td>add_date</td><td>dd_date</td><td>scr_date</td><td>senior_date</td><td>deputy_date</td><td>account_date</td><td>verify_date</td><td>enroll_date</td><td>uid</td><td>adm_status</td><td>pay</td><td>upload_status</td><td>deputy_last_date</td><td>cours_name1</td><td>cours_name2</td><td>rep</td><td>batch</td><td>exam_code</td><td>batch_prac</td><td>batch_tut</td><td>pre_course</td><td>sem_flag</td><td>session</td><td>admitted_session</td><td>session_for_paper</td><td>sem2batch</td><td>course_name_bak</td><td>sem_bak</td><td>adm_flag</td><td>Eng_proficiency</td><td>Short_term</td><td>deputy_fee</td><td>phd_enroll_dept</td><td>migrated</td><td>adm_sem</td></tr>
<?php
$GetList=mysql_query("SELECT * FROM  `student_registration`  WHERE  `step` =  '11' AND  `sesion` =9");
while($GetList1=mysql_fetch_assoc($GetList))
{
$s =$_REQUEST['v'];

						$u = $s+0;	
			$GetChkForm=mysql_query("SELECT * FROM  `only_sid` WHERE  `sid` ='$GetList1[sid]'");
			$GetChkForm1=mysql_num_rows($GetChkForm);
			if($GetChkForm1 > 0)
			{
			
	
	$GetPersonal=mysql_query("SELECT * FROM  `step1_perosonal` WHERE  `sid` =  '$GetList1[sid]'");
$GetPersonal1=mysql_fetch_assoc($GetPersonal);

$GetSem=mysql_query("SELECT * FROM  `sgvu_stu_sem_allocate` WHERE  `sid` ='$GetList1[sid]'");
$GetSem1=mysql_fetch_assoc($GetSem);


$GetEnroll=mysql_query("SELECT * FROM  `sgvu_enrollment` WHERE  `sid` ='$GetList1[sid]'");
$GetEnroll1=mysql_fetch_assoc($GetEnroll);


//$GetChk=mysql_query("SELECT * FROM  `sgvu_stu_sem_allocate` WHERE  `sid` ='$GetList1[sid]'");
//$GetChk1=mysql_fetch_assoc($GetChk);
//if($GetChk1['sem'] =='1')
{

?>
<tr><td><?php echo $_REQUEST['v'] = $u+1; ?></td><td><?php echo $GetList1['sid']; ?></td><td><?php 
$GetProg=mysql_query("SELECT * FROM  `sgvu_courses` WHERE  `course_id` =' $GetPersonal1[program]'");
$GetProg1=mysql_fetch_assoc($GetProg);
echo $GetProg1['coursename'];
 ?></td><td><?php echo $GetList1['sid']; ?></td><td><?php echo $GetList1['password']; ?></td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td><?php echo $GetEnroll1['enrollment_no']; ?></td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td><?php echo $GetSem1['sem']; ?> Sem</td><td>2016</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td><?php echo $GetSem1['sem']; ?> Sem</td></tr>
<?php
}
}
}
?>
</table>