    <?php
        $mdl = base64_decode($param3);
        $mdlEx = explode('-', $mdl);
    ?>
    <div class="modal-body">
        <div class="modal-header mdl-header">
            <h6 class="title text-white"><?php echo getEduAppGTLang('study_material');?></h6>
        </div>
        <div class="ui-block-content">
            <?php if($param2 == 'add'):?>
            <form action="<?php echo base_url();?>teacher/activities/study_material" method="POST" enctype="multipart/form-data">
                <input type="hidden" value="<?php echo $mdlEx[0];?>" name="class_id">
                <input type="hidden" value="<?php echo $mdlEx[1];?>" name="section_id">
                <input type="hidden" value="<?php echo $mdlEx[2];?>" name="subject_id">
                <input type="hidden" value="create" name="method">
                <div class="row">
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <div class="form-group label-floating">
                            <label class="control-label"><?php echo getEduAppGTLang('description');?></label>
                            <textarea class="form-control" name="description" required=""></textarea>
                        </div>
                    </div>
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <div class="mb-3">
                            <label><?php echo getEduAppGTLang('choose_file');?>:</label>
                            <input type="file" class="inputFile" name="file_name" required="">
                        </div>
                    </div>
                    <div class="col-sm-12">
                        <div class="checkbox-wrapper-4">
                            <input class="inp-cbx" id="showToStudents" name="status" value="1" type="checkbox"/>
                            <label class="cbx" for="showToStudents"><span>
                                <svg width="12px" height="10px">
                                    <use xlink:href="#check-4"></use>
                                </svg>
                                </span><span><?php echo getEduAppGTLang('show_message');?>.</span>
                            </label>
                            <svg class="inline-svg">
                                <symbol id="check-4" viewbox="0 0 12 10">
                                    <polyline points="1.5 6 4.5 9 10.5 1"></polyline>
                                </symbol>
                            </svg>
                        </div>
                    </div>
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <button class="btn btn-rounded btn-primary " type="submit"><?php echo getEduAppGTLang('upload');?></button>
                    </div>
                </div>
            </form>
            <?php elseif($param2 == 'edit'):?>
            <?php 
                $dataQ = $this->db->get_where('activity', array('activity_id' => $param3))->result_array();
                foreach($dataQ as $rm):
            ?>
            <form action="<?php echo base_url();?>teacher/activities/study_material/<?php echo $param3;?>" method="POST" enctype="multipart/form-data">
                <input type="hidden" value="<?php echo $rm['class_id'];?>" name="class_id">
                <input type="hidden" value="<?php echo $rm['section_id'];?>" name="section_id">
                <input type="hidden" value="<?php echo $rm['subject_id'];?>" name="subject_id">
                <input type="hidden" value="update" name="method">
                <div class="row">
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <div class="form-group label-floating">
                            <label class="control-label"><?php echo getEduAppGTLang('description');?></label>
                            <textarea class="form-control" name="description" required=""><?php echo $rm['description'];?></textarea>
                        </div>
                    </div>
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <div class="mb-3">
                            <label><?php echo getEduAppGTLang('choose_file');?>:</label>
                            <input type="file" class="inputFile" name="file_name">
                        </div>
                    </div>
                    <div class="col-sm-12">
                        <div class="checkbox-wrapper-4">
                            <input class="inp-cbx" id="showToStudents" <?php if($rm['status'] == 1) echo 'checked';?> name="status" value="1" type="checkbox"/>
                            <label class="cbx" for="showToStudents"><span>
                                <svg width="12px" height="10px">
                                    <use xlink:href="#check-4"></use>
                                </svg>
                                </span><span><?php echo getEduAppGTLang('show_message');?>.</span>
                            </label>
                            <svg class="inline-svg">
                                <symbol id="check-4" viewbox="0 0 12 10">
                                    <polyline points="1.5 6 4.5 9 10.5 1"></polyline>
                                </symbol>
                            </svg>
                        </div>
                    </div>
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <button class="btn btn-rounded btn-primary " type="submit"><?php echo getEduAppGTLang('update');?></button>
                    </div>
                </div>
            </form>
            <?php endforeach;?>
            <?php else:?>
            <?php 
                $dataQ = $this->db->get_where('activity', array('activity_id' => $param3))->result_array();
                foreach($dataQ as $rm):
            ?>
            <div class="row">
                <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                    <div class="form-group label-floating">
                        <label class="text-bold"><?php echo getEduAppGTLang('description');?></label>
                        <p class="mb-4"><?php echo $rm['description'];?></p>
                        <label class="text-bold"><?php echo getEduAppGTLang('uploaded_by');?></label>
                        <p class="mb-4"><img src="<?php echo $this->crud->get_image_url($rm['uploader_role'], $rm['uploader_id']);?>" width="20px"> <?php echo $this->crud->get_name($rm['uploader_role'], $rm['uploader_id']);?></p>
                        <label class="text-bold"><?php echo getEduAppGTLang('uploaded_date');?></label>
                        <p><?php echo $rm['date'];?></p>
                    </div>
                </div>
            </div>
            <?php endforeach;?>
            <?php endif;?>
        </div>
    </div>