Viewing file:      v_import_std.php (3.26 KB)      -rwxr-xr-x Select action/file-type:    (+) |   (+) |   (+) | Code (+) | Session (+) |   (+) | SDB (+) |   (+) |   (+) |   (+) |   (+) |   (+) |
 
<script language="JavaScript1.2">
 function checkDocCur() {
     var docCur;
 
     docCur = document.getElementById('uploadfile_cur').value;
 
     if(docCur=="") {
         alert("กรุณาป้อนแฟ้มข้อมูลหลักสูตร!!");
         return false;
     }
 }
 
 function checkDocStd() {
     var docStd;
 
     docStd = document.getElementById('uploadfile_std').value;
 
     if(docStd=="") {
         alert("กรุณาป้อนแฟ้มข้อมูลนักศึกษา!!");
         return false;
     }
 }
 </script>
 <table>
     <tbody>
         <tr>
             <td colspan="2"><b>1.ดาวน์โหลดแฟ้มข้อมูลหลักสูตร เพื่อกรอกข้อมูล <?php echo anchor(base_url().'uploads/esa/rg_Curriculum.csv', 'คลิกที่นี่');?></b></td>
         </tr>
         <tr>
             <td><b>2.อัพโหลดแฟ้มข้อมูลหลักสูตร</b></td>
             <td>
 <?php
             $attributes = array('id' => 'myform1', 'name' => 'myform1');
             echo form_open_multipart($this->config->item('sa_folder').'eregis2esa/cur_insert', $attributes);
 ?>
             <input type="file" id="uploadfile_cur" name="uploadfile_cur" />
             <input type="submit" id="btnUpload" name="btnUpload" value="อัพโหลดไฟล์" onClick="return checkDocCur()" />
             <?php echo form_close();?></td>
         </tr>
         <tr>
             <td colspan="2"><b>3.ดาวน์โหลดแฟ้มข้อมูลนักศึกษา เพื่อกรอกข้อมูล <?php echo anchor(base_url().'uploads/esa/rg_Student.csv', 'คลิกที่นี่');?></b></td>
         </tr>
         <tr>
             <td><b>4.อัพโหลดแฟ้มข้อมูลนักศึกษา</b></td>
             <td>
 <?php
             $attributes = array('id' => 'myform2', 'name' => 'myform2');
             echo form_open_multipart($this->config->item('sa_folder').'eregis2esa/std_insert', $attributes);
 ?>
             <input type="file" id="uploadfile_std" name="uploadfile_std" />
             <input type="submit" id="btnUpload" name="btnUpload" value="อัพโหลดไฟล์" onClick="return checkDocStd()" />
             <?php echo form_close();?></td>
         </tr>
     </tbody>
 </table>
 
 <p align="center"><?php echo $this->session->flashdata('msg_submit');?></p>
 
 <!-- <table class="tb_1">
     <thead>
         <tr>
             <th>ลำดับที่</th>
             <th>รหัสนักศึกษา</th>
             <th>ชื่อ-นามสกุล</th>
         </tr>
     </thead>
     <tbody>
  --><?php
 //    $attr = array('width' => '600', 'height' => '500', 'scrollbars' => 'yes', 'status' => 'yes', 'resizable' => 'yes', 'screenx' => '0', 'screeny' => '0');
 //    $i = 1;
 //    if(isset($rs_std) && $rs_std->num_rows()) {
 //        foreach ($rs_std->result() as $row_std) {
 ?>
 <!--         <tr class="<?php echo ($i % 2) ? "light1" : "light";?>">
             <td align="center"><?php echo $i;?></td>
             <td align="center"><?php echo $row_std->stdCode;?></td>
             <td><?php echo anchor_popup('esa/eregis2esa/profile/'.$row_std->stdId, $row_std->prefixName.$row_std->stdName.' '.$row_std->stdSurname, $attr);?></td>
         </tr>
  --><?php
 //        $i++;
 //        }
 //    } else {
 ?>
 <!--         <tr>
             <td colspan="3"><?php echo "แสดงข้อมูลนักศึกษาทั้งหมด";?></td>
         </tr>
  --><?php
 //    }
 ?>
 <!--     </tbody>
 </table> -->
  |