     <div class="content-wrapper">
        <!-- Content Header (Page header) -->
        <section class="content-header">
          <h1>
            Channellimo
            <small>Preview</small>
          </h1>
          <ol class="breadcrumb">
            <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
            <li><a href="#">Forms</a></li>
            <li class="active">Component</li>
          </ol>
        </section>
        
        <section class="content">
        	<div class="col-lg-12">
             <form action="" method="post">
             	<div class="box box-primary col-lg-8">
                	<div class="box-header with-border">
						<h3 class="box-title">FORM EDIT</h3>
					</div>
              
                    <div class="form-group col-lg-8">
                      <label for="carname">Car Name</label>
                        <select class="form-control" name="carname">
                        <?php 
			  			$sql = $this->db->query('SELECT * FROM `tblcar` ORDER BY `fullname`');
			  			foreach ($sql->result() as $car)
			  			{  
			  			?>
             			 <option  <?php echo $car->id == ''.$component->car_id.'' ? 'selected' : '' ?> value="<?php echo $car->id ?>"><?php echo $car->fullname ?></option> 
              			<?php }?>
						</select>
                    </div>
                    
                    <div class="form-group col-lg-8">
					   <label for="name">Name</label>
					   <input id="name" name="name" class="form-control" type="text" placeholder="Enter Cartype" value="<?php echo $component->name?>">
					</div>
                    
                    <div class="form-group col-lg-8">
					   <label for="name">Value</label>
					   <input id="value" name="value" class="form-control" type="text" placeholder="Enter Value" value="<?php echo $component->value?>">
					</div>
                    
                    <?php 
			  		if($component->status == 1){
					 	$authorize = "active";
					}elseif($component->status == 0){
					 	$authorize = "disactive";	
					}else{
					 	$authorize = "null";	
					}
			        ?>

                    <div class="form-group col-lg-8">
                    	<label for="status">Status</label>
						<div class="col-lg-12">
                        <input type="radio" name="status" class="flat-red" value="1" <?php echo $authorize == 'active' ? 'checked' : '' ?>> Active 
                        <input type="radio" name="status" class="flat-red" value="0" <?php echo $authorize == 'disactive' ? 'checked' : '' ?>> DisActive
                        </div> 
                    </div>
                    
                    <!--<div class="form-group col-lg-8">
                    	<label for="detail">Detail</label>
                    	<textarea id="textarea" name="detail" class="textarea" placeholder="Place some text here" style="width: 100%; height: 200px; font-size: 14px; line-height: 18px; border: 1px solid #ADADAD; padding: 10px;" ><?php //echo $brand->detail?></textarea>
                    </div>-->
                    
                    <div class="form-group col-lg-8">
                     <input type="submit" name="update_component" value="Update" class="btn btn-primary"/>
                     <button type="reset" class="btn btn-danger">Reset</button>
                    </div>
                    
                    
                </div>
             </form>
            </div>
        </section>
     </div>
