<!DOCTYPE html>
<html lang="en">
  <style>.bgColor {
width: 440px;
height:100px;
background-color: #F9D735;
}
.bgColor label{
font-weight: bold;
color: #A0A0A0;
}
#targetLayer{
float:left;
width:100px;
height:100px;
text-align:center;
line-height:100px;
font-weight: bold;
color: #C0C0C0;
background-color: #F0E8E0;
overflow:auto;
}
#uploadFormLayer{
float:right;
padding: 10px;
}
.btnSubmit {
background-color: #3FA849;
padding:4px;
border: #3FA849 1px solid;
color: #FFFFFF;
}
.inputFile {
padding: 3px;
background-color: #FFFFFF;
}
</style>  

   <body>

      

  <div class="container-fluid">
    <div class="panel col-md-12" style="background-color: #e9e9e9;box-shadow: 5px 5px 5px;">
                    
                     <div class="panel-body">
                    
                  
                     <form method="post" id="full_form" action="" enctype="multipart/form-data">
                        <div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
                           <h2>Employee Detail</h2>
                           <div class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
                             <div class="form-group">
                                 <label for="first_name">Driver Name</label>
                                 <input type="text" id="first_name" name="first_name" placeholder="Driver Name" class="form-control radius" />
                              </div>
                              <div class="form-group">
                                 <label for="phone">Phone</label>
                                 <input type="text" id="phone" name="phone" placeholder="Phone" class="form-control radius" />
                              </div>
                              <div class="form-group">
                                 <label for="email">Email Address</label>
                                 <input type="text" id="email" name="email" placeholder="Email Address" class="form-control radius" />
                              </div>
                           </div>
                           <div class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
                              <div class="form-group">
                                 <label for="address">Address</label>
                                 <input type="text" id="address" name="address" placeholder="Address" class="form-control radius" />
                              </div>
                              <div class="form-group">
                                 <label for="post_code">Post Code</label>
                                 <input type="text" id="post_code" name="post_code" placeholder="Post Code" class="form-control radius" />
                              </div>


                           </div>

                        </div>
                        <div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
                        
                           <h2>Contact Address Details</h2>
                           <div class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
                              <div class="form-group">
                                 <label for="pco_number">PCO Number</label>
                                 <input type="text" id="pco_number" name="pco_number" placeholder="PCO Number" class="form-control radius" />
                              </div>
                             
                              <div class="form-group">
                                 <label for="d_l_number">Driver License Number</label>
                                 <input type="text" id="d_l_number" name="d_l_number" placeholder="Driver License Number" class="form-control radius" />
                              </div>
                           </div>
                           <div class="col-xs-12 col-sm-12 col-md-6 col-lg-6">

                              <div class="form-group">
                                 <label for="uplaod">Uplaod Photo</label>
                                 <input type="file" name="driver[]" id="post_code" placeholder="Post Code" class="form-control radius" />
                              </div>
                              <div class="form-group">
                                 <label for="uplaod">Uplaod Photo</label>
                                 <input type="file" name="driver[]" id="post_code" placeholder="Post Code" class="form-control radius" />
                                 <div id="loader"><img src="images/image_loader.gif"/></div>
                              </div>
                            
                           
               <div class="form-group pull-right">
                  <button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
                  <input type="submit" onClick="document.getElementById('full_form').submit();" class="btn btn-primary" value="Add Record" />
               </div> 
               </form>
               
            </div>
         </div>
      </div>


      <!-- Modal - Update User details -->
      
      <!-- Placed js at the end of the document so the pages load faster -->

      <!--Core js-->


      
<script type="text/javascript">
$(document).ready(function () {
	$('#loader').hide();
});
$(document).ready(function (e) {
	
	$("#full_form").on('submit',(function(e) {
		e.preventDefault();
		$('#loader').show();
		var url11 = 'ajax/create_driver.php?'+new Date().getTime();
		$.ajax({
			
        	url: url11,
			type: "POST",
			data:  new FormData(this),
			contentType: false,
    	    cache: false,
			processData:false,
			success: function(data)
		    { 
			
			
					
			$('#loader').delay(500).fadeOut("slow");	
			//$("#gallery").html(data);
				alert(data);
		    },
		  	error: function() 
	    	{
	    	} 	        
	   });
	}));
});
</script>
   </body>
</html>
