<?php

 
session_start();


//call the db
//require_once 'includes/configuration.php';

require_once('../db/configuration.php');


//call all the functions
//include '../includes/functions.php';

//authentication
include '../includes/course_auth.php';

$errors = array();
$info = array();
$info_success = array();



//uid
if(isset($_GET['u']))
{
	$get_uid = $_GET['uid'];
	
	$flu = $_GET['flu'];
}


//uid
if(isset($_POST['u']))
{
	$post_uid = $_POST['u'];
	
	$flu = $_POST['flu'];
}


//get pin
//$pin =  get_pin();


//get application number 
//$application_number = get_application_number($pin);
  




?>

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Profile Preview</title>

    <!-- include all the css files, js files, database configuration and all other included stuffss -->
    <?php include '../includes/course_reg_includes.php'; ?>
    
    
    
    <!-- CSS code from Bootply.com editor -->
        
        <style type="text/css">
            body {
				padding-top:50px;
			}
			
			#masthead {
				min-height:250px;
			}
			
			#masthead h1 {
				font-size: 30px;
				line-height: 1;
				padding-top:20px;
			}
			
			#masthead .well {
				margin-top:8%;
			}
			
			@media screen and (min-width: 768px) {
				#masthead h1 {
					font-size: 50px;
				}
			}
			
			.navbar-bright {
				background-color:#111155;
				color:#fff;
			}
			
			.affix-top,.affix{
				position: static;
			}
			
			@media (min-width: 979px) {
			  #sidebar.affix-top {
				position: static;
				margin-top:30px;
				width:228px;
			  }
			  
			  #sidebar.affix {
				position: fixed;
				top:70px;
				width:228px;
			  }
			}
			
			#sidebar li.active {
				border:0 #eee solid;
				border-right-width:4px;
			}
			
					</style>
   
    
</head>

<body>

	<!-- header goes in here -->
    <?php include '../includes/course_header2.php'; ?>
    <!-- /header -->
   
   
    <!-- container -->
    <div class="container">
    	
       
            <div  style="height:20px">
              
            </div>
            
          
            <div class="row alert alert-info">
            	<div style="float:left; width:10%"></div>
                
                
                
                <div style="float:left; width:90%">
                
            		<h3 class="text-center"> <img src="../images/user_roles.png" />Applicant's - Acknowledgement Slip</h3>
                    <p class="info text-center">Please all applicants should print this slip</p>
            	</div>
            
            
            	
                
            </div><!-- /alert info -->
            
            
           
          
            <div class="row">
             <div class="col-md-12">
                <div class="col-md-6">
         
               		  <div class="panel panel-info">
                    	<div class="panel-heading" style="height:60px;"> Personal Data  <?php  $_SESSION['user_id']; ?>
                        
                         <a class="btn btn-primary btn-sm pull-right" href="../edit_profile.php?u=<?php echo $get_u; ?>&flu=<?php echo md5('100a') ?>&musty=<?php echo $_SESSION['user_id']; ?>&info=Please go through the fields carefully"> 
                         <span class="glyphicon glyphicon-pencil"> </span>&nbsp;&nbsp;
                         Edit Profile</a>
                        
                        <a href="javascript:doit()"> <img src="../images/print_big.png" border=0  class="pull-right" title="Print" height="30" width="45"> </a>
                        </div>
                        
                        <?php 
						//get all passed vs
						
						
						
						$q = "SELECT  u.user_id  AS userid,  u.first_name, u.other_names, u.maiden_name, u.gender,  u.email, 
							  u.birthdate, u.phone_number,  u.address, u.permanent_address, u.image,  u.state_id, 
							  u.lga_id, u.town, u.pin, u.serial_number, u.nok_name, u.nok_address, u.nok_number,
							   u.department_id, u.course_id, u.applied_department, u.applied_course, u.place_of_birth, 
							   u.religion, u.marital_status, u.number_of_children, u.course_considered, u.appointment, 
							   u.appointment1, u.appointment2, u.employer, u.employer1, u.employer2, u.frm, u.frm1, 
							   u.frm2, u.t, u.to1, u.to2, u.prizes, u.ref_name, u.ref_add, u.ref_name1, u.ref_add1, 
							   u.ref_name2, u.ref_add2, u.other_languages, u.disability, u.disability_explain,u.application_number,
								u.result_1, u.result_2, u.primary_cert, u.secondary_cert, u.indigene_cert,  
							  s.id as stateid, s.title as state_title, l.id as lid, l.title as lga_title , l.state_id as lstate_id,
							  d.id as did, d.title as dept_title,
							  c.id as cid , c.title as course_title
							  
						FROM users u,state s, lga l, departments d, courses c
						
						
						WHERE u.lga_id = l.id
						AND l.state_id = s.id
						AND u.applied_department = d.id
						AND u.applied_course = c.id
						AND u.user_id = '{$_GET['musty']}'";
						$r = mysqli_query($dbc, $q) ;
						
						if(mysqli_num_rows($r) > 0 )
						{
							$row  = mysqli_fetch_array($r,MYSQLI_ASSOC);
							
								
								?>
                        <div class="panel-body">
                        
                        	
                            <ul class="list-group">
                            	<li class="list-group-item" style="height:130px;"><span class="label label-info"> Profile </span>
                                <img class="img-rounded pull-right" src="../uploads/pictures/<?php echo $row['image']; ?>" height="100" width="100" /></li>
                            	<li class="list-group-item">Name: <?php echo $row['first_name'].' ' .$row['other_names'] ?> </li>
                                <li class="list-group-item">Maiden Name: <?php echo $row['maiden_name'] ?></li>
                                <li class="list-group-item">Gender: <?php echo $row['gender'] ?></li>
                                <li class="list-group-item">Religious Dinomination: <?php echo $row['religion'] ?></li>
                                <li class="list-group-item">Applied Department: <?php echo $row['dept_title'] ?></li>
                                <li class="list-group-item">Applied Course: <?php echo $row['course_title'] ?></li>
                                <li class="list-group-item">Alternative course to be condidered : <?php echo get_course_title($row['course_considered']); ?></li>
                                <li class="list-group-item">Email: <?php echo $row['email'] ?></li>
                                 <li class="list-group-item">Place of Birth: <?php echo $row['place_of_birth']; ?></li>
                                <li class="list-group-item">DOB: <?php echo $row['birthdate']; ?></li>
                                <li class="list-group-item">Phone No.: <?php echo $row['phone_number']; ?></li>
                                 <li class="list-group-item">Marital Status: <?php echo $row['marital_status']; ?></li>
                                  <li class="list-group-item">Number of Children: <?php echo $row['number_of_children']; ?></li>
                                 <li class="list-group-item">Town: <?php echo $row['town']; ?></li>
                                <li class="list-group-item">Address: <?php echo $row['address']; ?></li>
                                <li class="list-group-item">Permanent Add: <?php echo $row['permanent_address']; ?></li>
                                <li class="list-group-item">State: <?php echo $row['state_title']; ?></li>
                                <li class="list-group-item">L.G.A: <?php echo $row['lga_title']; ?></li>
                               <?php /*?> <li class="list-group-item">town: <?php echo $row['town']; ?></li><?php */?>
                                <li class="list-group-item">Next of Kin: <?php echo $row['nok_name']; ?></li>
                                <li class="list-group-item">Next of Kin, Tel: <?php echo $row['nok_number']; ?></li>
                                 <li class="list-group-item">Next of Kin, Add: <?php echo $row['nok_address']; ?></li>
                                
                                <li class="list-group-item"><span class="label label-info"> Transaction Details </span></li>
                                <li class="list-group-item">PIN.: <?php echo $row['pin']; ?></li>
                                <li class="list-group-item">S/N.: <?php echo $row['serial_number']; ?></li>
                                
                                <li class="list-group-item"><span class="label label-info">Employment Details </span></li>
                  	            <li class="list-group-item">1. Appointment: <?php echo $row['appointment']; ?> <br/> Employer: <?php echo $row['employer']; ?> <br/> From: <?php echo $row['frm']; ?> <br/> To: <?php echo $row['t']; ?>  </li>
                                
                	             <li class="list-group-item">2. Appointment: <?php echo $row['appointment1']; ?> <br/> Employer: <?php echo $row['employer1']; ?> <br/> From: <?php echo $row['frm1']; ?> <br/> To: <?php echo $row['to1']; ?>  </li>
                                
                              <li class="list-group-item">3. Appointment: <?php echo $row['appointment2']; ?> <br/> Employer: <?php echo $row['employer2']; ?> <br/> From: <?php echo $row['frm2']; ?> <br/> To: <?php echo $row['to2']; ?>  </li>
                                 
                              <li class="list-group-item"><span class="label label-info"> Referees </span></li>
                              <li class="list-group-item">1. Name: <?php echo $row['ref_name']; ?> <br /> Address: <?php echo $row['ref_add']; ?> </li>
                              <li class="list-group-item">2. Name: <?php echo $row['ref_name1']; ?> <br /> Address:  <?php echo $row['ref_add1']; ?> </li>
                              <li class="list-group-item">3. Name: <?php echo $row['ref_name2']; ?> <br /> Address: <?php echo $row['ref_add2']; ?> </li>
                                 
                                 
                    	      <li class="list-group-item"><span class="label label-info"> Others</span></li>
                              <li class="list-group-item">Acadamic Distinctions or Prizes: <?php echo $row['prizes']; ?></li>
                              <li class="list-group-item">Knowledge of languages other than English: <?php echo $row['other_languages']; ?></li>    
                              <li class="list-group-item">Disability: <?php echo $row['disability']; ?></li>
                              <li class="list-group-item">Reason(Disability): <?php echo $row['disability_explain']; ?></li>
                             
                            
                            </ul>
                        
                        <?php 
						
							
						}
                        ?>
                        </div>
                        <div class="panel-footer" style="height:60px;"> <?php echo date('Y:M:D H:i:s') ; ?>
                        
                        
                               <a class="btn btn-primary btn-sm pull-right" href="../edit_profile.php?u=<?php echo $get_u; ?>&flu=<?php echo md5('100a') ?>&info=Please go through the fields carefully"> <span class="glyphicon glyphicon-pencil"> </span>&nbsp;&nbsp;
                         Edit Profile</a>
                        
                        <a href="javascript:doit()"> <img src="../images/print_big.png" border=0  class="pull-right" title="Print" height="30" width="45"> </a>
                        </div>
                    </div><!-- /panel -->

                
                
                
                  
                </div><!-- /col-md-6 -->
               
                
                <div class="col-md-6">
                <!-- notification -->
                <?php   include '../includes/notifications.php'; //show notification  ?>
                 <h4 class="label label-info text-center" >Downloads</h4>
                
                <ul class="list-group">
                
                	<li class="list-group-item">
                      <span class="glyphicon glyphicon-chevron-right"></span> 
                    
                      <a class="btn btn-danger btn-sm" href="uploads/documents/Guarantors_form.pdf"> 
                      <span class="glyphicon glyphicon-circle-arrow-down"> </span>&nbsp;&nbsp;&nbsp;Download Guarantor's Form</a>
                    </li>
                    
                    <li class="list-group-item">
                      <span class="glyphicon glyphicon-chevron-right"></span> 
                    
                      <a class="btn btn-danger btn-sm" href="uploads/documents/Online_Application Guide.pdf">
                      <span class="glyphicon glyphicon-circle-arrow-down"> </span>&nbsp;&nbsp;&nbsp;Download Online Appliation Guide</a>
                    </li>
                    <li class="list-group-item">
                      <span class="glyphicon glyphicon-chevron-right"></span> 
                    
                      <a class="btn btn-danger btn-sm" href="uploads/documents/SCHOOL_ORIENTATION PROGRAMME.pdf"> <span class="glyphicon glyphicon-circle-arrow-down"> </span>&nbsp;&nbsp;&nbsp;Download School Orientation Programme</a>
                    </li>
                    <li class="list-group-item">
                      <span class="glyphicon glyphicon-chevron-right"></span> 
                    
                      <a class="btn btn-info btn-sm" href="javascript:doit()"><span class="glyphicon glyphicon-print"> </span>&nbsp;&nbsp;&nbsp;Print Current Page</a>
                    </li>
                   
                     
                    
                </ul>
                    
                    
                    </div>
                  </div><!-- /col-md-6 -->
               
            </div><!-- /col-md-8 -->
               
              
     	        
                 <br/>
                <br/>
                <br/>
                
               
                
                
                <!-- sign up on social media -->
                <div class="row">
                  <div class="col-md-6 text-center">
                      <h1 style="font-weight:bold; color:#CCC;">JOIN OUR SOCIAL NETWORK</h1>
                  </div>
                  
                  <div class="col-md-6 text-center">
                      
                      
                     
                      <a class="btn btn-md btn-info" href="#"> TWITTER</a>
                      <a class="btn btn-md btn-primary" href="#"> FACEBOOK</a>
                  </div>
                  
              	</div>
                <!-- /row -->
        

				
              
    

	
	
	
	<!-- footer starts -->
	<?php include '../includes/footer.php';?>


    </div>
    <!-- /.container -->

    <!-- JavaScript -->
     <!-- call the jquery files, so as not to slow the web page -->
    <?php include '../js/jquery_plugins.php'; ?>
    

    
</body>

</html>
