<div class="row">
  <div class="col-lg-12 mt-4">
    <div class="card">
      <div class="card-header form-card-header">
        <h4 class="m-b-0 text-light">UPDATE GOVERNMENT</h4>
      </div>
      <div class="card-body">
        <form id="update_government" class="form-material">
          <div class="form-body">
            <div class="row">
              <div class="col-md-12">
                <div class="form-group">
                  <label class="control-label"><strong>TITLE <span>*</span></strong></label>
                  <input type="text" id="title" name="title" class="form-control"  autocomplete="off" maxlength="255" required="" value="<?php echo $government[0]->title; ?>">
                  <label for="title" class="error"></label> 
                </div>
              </div>

              <div class="col-md-12">
                <div class="form-group">
                  <label class="control-label"><strong>OVERVIEW </strong></label>
                  <textarea class="form-control"  autocomplete="off" maxlength="100" name="overview" id="overview" rows="3"><?php echo $government[0]->overview; ?></textarea>
                  <label for="overview" class="error"></label> 
                </div>
              </div>

              <div class="col-md-6">
                <div class="form-group">
                  <label class="control-label"><strong>UPLOAD FILE <span>*</span></strong></label>
                  <input type="file" id="pdf" name="pdf" class="form-control"  autocomplete="off" >
                  <label> Max file size : 5 mb allowed. </label>
                  <label for="pdf" class="error"></label> 
                </div>
              </div>

              <div class="col-md-3 offset-3">
                <div class="form-group">
                  <a class="btn btn-block btn-info" target="_blank" href="<?php echo base_url().$government[0]->filepath; ?>"><i class="fa fa-file-pdf-o" aria-hidden="true">  VIEW FILE</i></a>
                </div>
              </div>

              <div class="col-md-12">
                <div class="form-group">
                  <label class="control-label"><strong>STATUS</strong></label>
                  <select name="status" id="status" class="form-control"  autocomplete="off" >
                    <option value="1" <?php if($government[0]->status == '1'){echo 'selected'; }?>>ACTIVE</option>
                    <option value="0" <?php if($government[0]->status == '0'){echo 'selected'; }?>>DEACTIVE</option>
                  </select>
                  <label for="status" class="error"></label> 
                </div>
              </div>
            </div>
           
            <input type="hidden" id="id" name="id" value="<?php echo $government[0]->id; ?>">
            <input type="hidden" id="pdf_path" name="pdf_path" value="<?php echo $government[0]->filepath; ?>">
          </div>

          <div class="form-actions">
            <button type="submit" class="btn btn-rounded btn-outline-success col-md-3">SAVE</button>  
            <button type="button" class="btn btn-rounded btn-outline-danger col-md-3" onclick="window.location.href='<?php echo base_url(); ?>government/list'">CANCEL</button>  
          </div>
        </form>
      </div>
    </div>
  </div>
</div>