Current File : /home/inlingua/public_html/sensoriumpsychologists.com/backup/admin/list_student_profile_request.php
<?php 
include_once('include/include.script.php');
include_once('include/navigation.php');
include_once('../classes/config.php');
?>
<?php
$result=$query->select_where('shristi_students_details','status','2');
?>
<?php
//multiple value
// Check if delete button active, start this 
	error_reporting(0);
		
//multiple enable
		if(isset($_POST['enable'])){
			$sql1 = "UPDATE shristi_students_details  SET status='0' WHERE student_id='$status' AND status='1'";
			$result1=$conn->query($sql1);
	  		$checkbox = $_POST['checkbox'];
			if($checkbox==""){
			echo "<script>alert('please select at list one id');</script>";	
			}else{
				for($i=0;$i<count($checkbox);$i++){
				$status = $checkbox[$i];
				$sql = "UPDATE shristi_students_details  SET status='1' WHERE student_id='$status'";
				$result=$conn->query($sql);
			}
// if successful redirect to delete_multiple.php 
			if($result){
				echo "<meta http-equiv=\"refresh\" content=\"0;URL=list_student_profile_request.php\">";
				}
			}
	}
?>
<div id="main">
			<div class="container-fluid">
				<div class="page-header">
					<div class="pull-left">
						<h1>student edit profile request</h1>
					</div>
					<div class="pull-right">
						<ul class="stats">
							<li class='lightred'>
								<i class="icon-calendar"></i>
								<div class="details">
									<span class="big">February 22, 2013</span>
									<span>Wednesday, 13:56</span>
								</div>
							</li>
						</ul>
					</div>
				</div>
				<div class="breadcrumbs">
					<ul>
						<li>
							<a href="home.php">Home</a>
							<i class="icon-angle-right"></i>
						</li>
						<li>
							<a href="">student edit profile request</a>
							<i class="icon-angle-right"></i>
						</li>
						
					</ul>
					<div class="close-bread">
						<a href="#">
							<i class="icon-remove"></i>
						</a>
					</div>
				</div>
				<div class="row-fluid">
					<div class="span12">
						<div class="box box-bordered">
							<div class="box-title">
								<h3>
									<i class="icon-table"></i>student edit profile request 
                                </h3>
							</div>
                            <form method="post" enctype="multipart/form-data">
							<div class="box-content nopadding">
                            <table class="table table-hover table-nomargin dataTable dataTable-tools table-bordered">
									<thead>
										<tr>
											<th class='with-checkbox'><input type="checkbox" name="check_all" id="check_all"></th>
											<th>Name</th>
                                            <th>Email</th>
                                            <th>old  Number</th>
                                            <th>new  Number</th>
                                            <th>old  per-Address</th>
                                            <th>new  per Address</th>
                                            <th>old  curr-Address</th>
                                            <th>new  curr-Address</th>
                                           <th class='hidden-350'>Status</th>
											<th class='hidden-480'>Options</th>
										</tr>
									</thead>
									<tbody>
             <?php 
			 	while($row=$result->fetch_assoc()){
				$result1=$query->select_where_field('shristi_students_details','status','1',"AND student_id=".$row['student_id']."");
				$row1=$result1->fetch_assoc();	
			 ?>       
							<tr>
								<td class="with-checkbox">
									<input type="checkbox" name="checkbox[]" value="<?php echo $row['student_id'];?>">						  								 </td>
                             <?php 
								$results=$query->select_where('shristi_student','student_id',$row['student_id']);
								$frow=$results->fetch_assoc();?>  
                                <td><?php echo $frow['fname'];?> <?php echo $frow['lname'];?></td>
                                <td><?php echo $frow['email'];?></td>
                                <td><?php echo $row1['mobile1'];?></td>
                                <td><?php echo $row['mobile1'];?></td>
                                <td><?php echo $row1['p_address'];?></td>
                                <td><?php echo $row['p_address'];?></td>
                                <td><?php echo $row1['c_address'];?></td>
                                <td><?php echo $row['c_address'];?></td>
                                
                            
                                             
                                     		<td class='hidden-350'><?php
												if($frow['status']==1){echo "<span class='label label-satgreen'>Active</span>";}
												if($frow['status']==0){echo "<span class='label label-lightred'>Inactive</span>";}?></td>
											<td class='hidden-480'>
                                            <a href="view_student_detail.php?id=<?php echo $row['student_id'];?>" class="btn" rel="tooltip" title="" data-original-title="View"><i class="icon-search"></i></a>
                                            </td>
										</tr>
					<?php } ?>					
									</tbody>
								</table>
                                
							</div>
                               <i class="icon-ok"><input type="submit" name="enable" value="Apporve" class="btn btn-info delet" onclick="return confirm('sure to Active !');"></i>
                        </div>
                        </form>
					</div>
				</div>
			</div>
		</div>
	</div>
	
<?php include_once('include/footer.php');?>