<?php 
  ob_start();
  session_start();
  error_reporting( ~E_NOTICE );
  require_once '../includes/conn.php';
  require_once '../includes/dbconfig.php';
  include('../scripts2.php'); 
  ?> 
  
<!DOCTYPE html>
<html lang="en">

<head>
<?php   require_once 'head_link.php'; ?>

<style type="text/css"> 
.left{width:30%;}
</style>

</head>

<body class="bg-white">
 
<?php //  require_once 'header1.php'; ?> 
<?php 
if(isset($_GET['view']) && !empty($_GET['view']))
{
    
    $customer_id = $_GET['view'];
    
    $stmt_edit = $DB_con->prepare('SELECT * FROM customer 
   
    LEFT JOIN batch ON batch.id = customer.batch_no
    LEFT JOIN product ON product.product_id = customer.course_id 
    LEFT JOIN cust_position ON cust_position.id = customer.position 
    LEFT JOIN degree ON degree.deg_id = customer.last_edu 
    
	
	WHERE customer.customer_id = :uid'); 
	
    $stmt_edit->execute(array(':uid' => $customer_id));
    $edit_row = $stmt_edit->fetch(PDO::FETCH_ASSOC);
    extract($edit_row);
}
else
{
    header("Location: index");
}
?>

 

 
 

<?php // require_once 'sidebar.php'; ?>


    <section class="section bg-white">
      <div class="row1">
    <div class="col-lg-7 m-auto mt-3  pb-5 border rounded">
 
     
    
	<table class="table table-hover table-responsive mb-5 ">
	
	<tr>  
            <?php 
$sql = $con->query("select * from stuff where userid ='".$_SESSION['id']."' ");
$row = $sql->fetch_assoc();
$BizLogo =$row['photo'];
$BizNam =$row['business_name'];
$BizDetails =$row['business_details'];
$BizPhn =$row['business_phone']; 
$BizEml =$row['business_email'];
$BizWeb =$row['biz_web'];
$BizAdr =$row['business_address'];
?>
            
    <header class="clearfix text-center">
      <div id="logo">
	  <img src="../<?php if($BizLogo==""){echo "../img/user.jpg";}else{echo $BizLogo;} ?>" width="130px"> 
      </div>
      <div id="company"> 
        <h3 class="name"><b><?php echo $BizNam ; ?></b> <br><?php echo $BizDetails ; ?></h3>
     </div>
      </div>
    </header>
            
	</tr>
   
	
	<tr>
	<div class="mt-4 mb-2"> 
	<img class="" src="user_images/<?php echo $userPic; ?>" width="120" />
	<h5><strong><?php echo $customer_name; ?> </strong><br>
	<strong>Batch : </strong> <?php echo $batch_name; ?><br>
	<strong>Course Name : </strong> <?php echo $product_name; ?>
	</h5> 
	</div>
	</tr>
	
	 <tr>
	 <td></td> <td></td>
	 </tr>
	
		
	<tr>
    	<td><label class="control-label">Full Name</label></td>
    	<td><label class="control-label"><?php echo $customer_name; ?></label></td>
    </tr>
	
	<tr>
    <td><label class="control-label">Gender</label></td>
    <td><label class="control-label"><?php echo $gender; ?></label></td>
	</tr>
	
	<tr>
    	<td><label class="control-label">Profession</label></td>
    	<td><label class="control-label"><?php echo $position_name; ?></label></td>
    </tr>
	
	<tr>
    	<td><label class="control-label">Father Name</label></td>
    	<td><label class="control-label"><?php echo $father_name; ?></label></td>
    </tr>
	
	
	<tr>
    	<td><label class="control-label">Mother Name</label></td>
    	<td><label class="control-label"><?php echo $mother_name; ?></label></td>
    </tr>
	    
	<tr>
    	<td><label class="control-label">Address</label></td>
    	<td><label class="control-label"><?php echo $address; ?></label></td>
    </tr>
	
	<tr>
    	<td><label class="control-label">Phone No</label></td>
    	<td><label class="control-label"><?php echo $contact_info; ?></label></td> 
    </tr>
	
	<tr>
    	<td><label class="control-label">E-Mail</label></td>
    	<td><label class="control-label"><?php echo $email; ?></label></td> 
    </tr>
	
	<tr>
    	<td><label class="control-label">Marriage Info</label></td>
    	<td><label class="control-label"><?php echo $marriage_info; ?></label></td> 
    </tr>
	
	<tr>
    	<td><label class="control-label">Religion</label></td>
    	<td><label class="control-label"><?php echo $religion; ?></label></td> 
    </tr>
	
	<tr>
    	<td><label class="control-label">Last Education Qualification</label></td>
    	<td><label class="control-label"><?php echo $deg_name; ?></label></td> 
    </tr>
	
	<tr>
    	<td><label class="control-label">School/College/University</label></td>
    	<td><label class="control-label"><?php echo $school; ?></label></td> 
    </tr>
	
    <tr>
    	<td><label class="control-label">Guardian / Phone</label></td>
    	<td><label class="control-label"><?php echo $gar_phn; ?></label></td> 
    </tr>
	
    <tr>
    	<td><label class="control-label">Reference ( Name/Phone/Address )</label></td>
    	<td><label class="control-label"><?php echo $refers; ?></label></td> 
    </tr>
	
    <tr>
    	<td><label class="control-label">Admission Date</label></td>
    	<td><label class="control-label"><?php echo date("d-M-Y", strtotime($join_date) ); ?></label></td> 
    </tr>
 
	
		 
    </table>
	
 
    <br><br><br><br><br>
	
	 <footer class="text-center mt-5 ">       
      <div id="company">  
       <div><?php echo $BizAdr ; ?></div>  
      <div>Call : <?php echo $BizPhn ; ?>, Email : <a href="mailto:<?php echo $BizEml ; ?>"><?php echo $BizEml ; ?></a> , Website : <?php echo $BizWeb ; ?></div>
	  </div>
      </div>
    </footer>
        </div>

        </div>

      
    </section>


    <?php // require_once 'footer1.php'; ?>