
 
   <div class="container-fluid">
 <div class="row">

  <div class="col-xs-12 col-sm-6 col-lg-12">
  
		<div class="panel panel-primary" data-collapsed="0">
        	<div class="panel-heading">
            	<div class="panel-title" id="redcolor" >
            		<i class="entypo-plus-circled"></i>
				Please Enter Correct Details of the New District
            	</div>
            </div>
			<div class="panel-body">

			
										
					<div class="row">
						<div class="col-md-12">
							
							<div class="panel-body">
							
					
	
				<?PHP
 echo $this->session->flashdata('msg'); 
		?>
		
		
			<?PHP
				$session_data = $this->session->userdata('adminlogged_in');


		
                 echo form_open('admin/adddistrict' , array('class' => 'form-horizontal form-groups-bordered validate', 'enctype' => 'multipart/form-data'));
				 if(validation_errors()):?>
<div class='alert alert-danger text-center'><?php echo validation_errors(); ?></div>
<?php endif;?>
					
	


	<div class="form-group">
    <label for="inputname" class="col-sm-2 control-label">	District Name</label>
    <div class="col-sm-10">

		  		<input type="text" name="name" value="<?php echo set_value('name'); ?>"id="name" class="form-control"  placeholder="Enter program Name">
		 
				
		<span class="text-danger"> 	Enter District name  here..<?php echo form_error('name'); ?>
		
		</span>
	</div>
  </div>	

	

  

	<div class="form-group">
    <label for="inputdescription" class="col-sm-2 control-label">	District Description</label>
    <div class="col-sm-10">

<textarea name="description" rows="2" cols="10" class="form-control">
		<?php echo set_value('description'); ?>	
</textarea>		
		<span class="text-danger"> Enter description if any<?php echo form_error('description'); ?>
		
		</span>
	</div>
  </div>
		
  
  
	 <div class="form-group">
	<button type="submit" name="btn_district" class="btn btn-primary" value="district">
                                <span class="glyphicon glyphicon-log-in"></span> Add district                           
								 </button>
    </div>
  </div>
			</div>							   
									<?php echo form_close();?>

							
						</div>
					</div>

 
  <table cellpadding="0" cellspacing="0" border="0" class="table  table" id="example" style="border-color:#CCCCCC; width:100%;"  >

  <tr>

    <th>district Code</th>

    <th>district Name</th>    

    <th>district Description</th>    

    <th>Action</th>    

  </tr>

<?php 
		 $district = $this->districtmodel->populatedistrict();

if(is_array($district)) {

   foreach($district as $row){

  echo "<tr>";

    

    echo "<td>". $row->id ."</td>";

    echo "<td>". $row->name ."</td>";

    echo "<td>". $row->description ."</td>";
      echo "<td>". "Update  Delete"."</td>";

 

}} else {
    echo 'There is no any district data available.... try again.';
}

 echo "</tr>";   




?>

</table>
				
					
					
					
					
					
					
					
					
					
					
					
					
					
					
					
					
					
			
			</div>
		</div>
  
  </div>
 
</div>




















































