<select data-errormessage-value-missing="Course is required"
        class="form-control validate[required]" 
        name="course" id="course"
        onchange="adminViewBatchByCourse(this.value, '<?php echo base_url('super_admin_batch/view_batch_by_course'); ?>')">
    <option value=""> <?php
        if (isset($course_type)) {
            echo $course_type;
        }
        ?></option>
    <?php 
    if(isset($courses)){
    foreach ($courses as $v_courses) { ?>
        <option value="<?php echo $v_courses->course_id; ?>"><?php echo $v_courses->course_name; ?></option>
    <?php }} ?>
</select>