    <?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('video');?></h6>
        </div>
        <div class="ui-block-content">
            <?php if($param2 == 'add'):?>
            <form id="YTForm" action="<?php echo base_url();?>admin/activities/video" method="POST">
                <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">
                <iframe class="mb-3 hidden" id="player" width="100%" height="170"></iframe>
                <div class="form-group mb-3">
        		    <label><?php echo getEduAppGTLang('youtube_url');?>:</label>
    		        <input class="form-control" onblur="loadVideo()" name="url" type="text" id="url" required="">
    		    </div>
                <div class="form-group mb-3">
                    <label><?php echo getEduAppGTLang('description');?>:</label>
                    <textarea class="form-control" name="description" required=""></textarea>
                </div>
                <input type="hidden" id="duration" name="duration">
                <input type="hidden" id="embed" name="embed">
                <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 class="row">
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <button class="btn btn-rounded btn-primary" id="YTBtn" type="submit"><?php echo getEduAppGTLang('create');?></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 id="YTForm" action="<?php echo base_url();?>admin/activities/video/<?php echo $param3;?>" method="POST">
                <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">
                <iframe class="mb-3 hidden" id="player" width="100%" height="170"></iframe>
                <div class="form-group mb-3">
                    <label><?php echo getEduAppGTLang('description');?>:</label>
                    <textarea class="form-control" name="description" required=""><?php echo $rm['description'];?></textarea>
                </div>
                <?php if($rm['isDuration'] == 0):?>
                <div class="form-group mb-3">
                    <label><?php echo getEduAppGTLang('enter_manually_duration');?>:</label>
                    <input class="form-control" name="dur" required="" value="<?php echo $rm['duration'];?>">
                </div>
                <?php endif;?>
                <div class="checkbox-wrapper-4">
                    <input class="inp-cbx" id="showToStudents" name="status" <?php if($rm['status'] == 1) echo 'checked';?> 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 class="row">
                    <div class="col col-lg-12 col-md-12 col-sm-12 col-12">
                        <button class="btn btn-rounded btn-primary" id="YTBtn" 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="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>
            <iframe width="100%" height="350px" src="<?php echo $rm['url'];?>" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>
            <?php endforeach;?>
            <?php endif;?>
        </div>
    </div>
    <script src="https://www.youtube.com/iframe_api"></script>
    <script src="<?php echo base_url();?>public/style/js/subject.js"></script>