<!-- begin:: Subheader -->
<div class="kt-subheader   kt-grid__item" id="kt_subheader">
<div class="kt-container  kt-container--fluid ">
    <div class="kt-subheader__main">
       <div class="kt-subheader__breadcrumbs">
            <a class="kt-subheader__breadcrumbs-link">
                Courses </a>
            <span class="kt-subheader__breadcrumbs-separator"></span>
            <a class="kt-subheader__breadcrumbs-link">
                Add Courses </a>
            <span class="kt-subheader__breadcrumbs-separator"></span>
            
        </div>
    </div>                                        
</div>
</div>
<!-- end:: Subheader -->
<!-- begin:: Content -->
<div class="kt-container  kt-container--fluid  kt-grid__item kt-grid__item--fluid">
   <div class="kt-portlet">
      <div class="kt-portlet__body kt-portlet__body--fit">
         <div class="kt-grid  kt-wizard-v1 kt-wizard-v1--white" id="kt_projects_add" data-ktwizard-state="first">            
            <div class="kt-grid__item kt-grid__item--fluid kt-wizard-v1__wrapper">
               <!--begin: Form Wizard Form-->
               <form class="kt-form" id="kt_form" action="<?=base_url();?>admin/process_edit_course/<?=$course_details[0]['id'];?>" method="post" novalidate="novalidate">
                  <!--begin: Form Wizard Step 1-->
                  <div class="kt-wizard-v1__content" data-ktwizard-type="step-content" data-ktwizard-state="current">
                     <div class="kt-heading kt-heading--md">Course Information:</div>
                     <div class="kt-section kt-section--first">
                        <div class="kt-wizard-v1__form">
                           <div class="row">
                              <?php $validation = \Config\Services::validation(); ?>
                              <div class="col-xl-12">
                                 <div class="kt-section__body">
                                    <div class="form-group row <?= $validation->hasError('cousre_name') ? 'has-error' : ''; ?>">
                                    <label class="col-xl-3 col-lg-3 col-form-label">Course Name 
                                        <span class="required"> * </span>
                                    </label>
                                    <div class="col-lg-9 col-xl-9">
                                        <input type="text" name="cousre_name"  id="cousre_name" placeholder="Enter Course Name" class="form-control input-height" value="<?=(old('cousre_name') ? old('cousre_name') :$course_details[0]['name']);?>" required/> 
                                        <span class="help-block"> <?= $validation->getError('cousre_name'); ?> </span>
                                        </div>
                                </div>
                                 <div class="form-group row <?= $validation->hasError('course_year') ? 'has-error' : ''; ?>">
                                    <label class="col-xl-3 col-lg-3 col-form-label">Semester
                                        <span class="required"> * </span>
                                    </label>
                                    <div class="col-lg-9 col-xl-9">
                                        <input type="text" name="course_year" id="course_year" placeholder="Enter Course Semester" class="form-control input-height" value="<?=(old('course_year') ? old('course_year') :$course_details[0]['years']);?>" required/> 
                                        <span class="help-block"> <?= $validation->getError('course_year'); ?> </span>
                                        </div>
                                </div>                                          
                                <div class="form-group row">
                                    <label class="col-xl-3 col-lg-3 col-form-label">Status
                                        <span class="required"> * </span>
                                    </label>
                                    <div class="col-lg-9 col-xl-9"> 

                                       <?php $selectedStatus = old('status', $course_details[0]['status']); ?>

                                       <input type="radio" 
                                             name="status" 
                                             id="optionsRadios" 
                                             value="1"
                                             <?= ($selectedStatus == '1') ? 'checked' : ''; ?> />

                                       <label for="optionsRadios">
                                          Active 
                                       </label>

                                       <input type="radio" 
                                             name="status" 
                                             id="optionsRadios1" 
                                             value="2"
                                             <?= ($selectedStatus == '2') ? 'checked' : ''; ?> />

                                       <label for="optionsRadios1">
                                          Inactive
                                       </label>                                                                        

                                    </div>
                                </div>                                
                                    
                                 </div>
                              </div>
                           </div>
                        </div>
                     </div>
                  </div>
                  <!--end: Form Wizard Step 1-->         
                 <!--begin: Form Actions -->
                  <div class="kt-form__actions">                    
                     <button type="Submit" class="btn btn-brand btn-md btn-tall btn-wide kt-font-bold kt-font-transform-u" data-ktwizard-type="action-next">
                        Submit
                     </button>
                  </div>
                  <!--end: Form Actions -->
               </form>
               <!--end: Form Wizard Form-->
            </div>
         </div>
      </div>
   </div>
</div>