Viewing file: FrmTeacher.php (4.95 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
session_start();
/** Define Validate Access */
define( '_VALID_ACCESS', 1 );
/** Check Session User Login */
if (! session_is_registered("valid_user") ) {
echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=windows-874\" />";
echo "<p style=padding-top:115px><p align=center><br /><font color=red><strong>กรุณาทำการ Login ก่อน</strong></font></p></p>";
echo "<meta http-equiv=\"refresh\" content=\"1; URL=../login.php\" />";
exit();
}
else {
/** Configuration */
require_once( "../configuration.php" );
require_once( $_Config_absolute_path . "/includes/framework.php" );
require_once( "../includes/FunctionDB.php" );
/** Create Database Object */
$dbObj = new DBConn;
$sql ="SELECT * FROM research_char_tb WHERE RecharId ='$RecharId' " ;
$result = mysql_query($sql) or die(" Error").mysql_error();
$rs = mysql_fetch_array($result);
} # else
?>
<meta http-equiv="Content-Type" content="text/html; charset=TIS-620">
<link href="../css/default.css" rel="stylesheet" type="text/css" />
<script language="javascript" src="../js/utilities.js"></script>
<table width="459" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="459" height="163"><br>
<fieldset>
<form action="EditTeacher.php" method="post" enctype="multipart/form-data" name="pc" id="pc">
<table width="96%" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#CCCCCC" style="border:0px solid gray;">
<tr bgcolor="#BFD0E6">
<td height="24" colspan="3" align="center" bgcolor="#FFFFFF">แก้ไขข้อมูล ผู้ร่วมผลงาน</td>
</tr>
<tr bordercolor="#99CCFF" bgcolor="#86ade2">
<td align="right" bgcolor="#FFFFFF">ชื่อผู้ทำผลงาน</td>
<td bgcolor="#FFFFFF"> </td>
<td bgcolor="#FFFFFF"><font size="2" face="Tahoma"><strong><font color="#003366" size="2" face="Tahoma">
<select name="Teacher_code" id="Teacher_code">
<option value=""></option>
<?php
$sql1 = " SELECT *, prefixName as First_name FROM personal_tb LEFT JOIN prefix ON personal_tb.First_name = prefix.prefixId ORDER BY Teacher_name ASC ";
$result1 = mysql_query($sql1);
while( $rs4 = mysql_fetch_array($result1) ) {
?>
<option value="<?=$rs4['Teacher_code'];?>" <?php if( $rs4['Teacher_code']==$rs['Teacher_code'] ) echo 'selected';?>>
<?=$rs4['Teacher_name'];?>
<?=$rs4['Teacher_lastname'];?>
</option>
<?php
} # while
mysql_free_result($result1);
?>
</select>
</font></strong></font></td>
</tr>
<tr bgcolor="#eeeeee">
<td height="16" align="right" bordercolor="#CCCCCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF" > </td>
</tr>
<tr bgcolor="#eeeeee">
<td width="27%" height="30" align="right" bordercolor="#CCCCCC" bgcolor="#FFFFFF">ตำแหน่งการทำผลงาน</td>
<td width="1%" bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td width="72%" bordercolor="#FFFFCC" bgcolor="#FFFFFF" >
<input type="radio" name="R_position" <?php if (!(strcmp("$rs[R_position]","หัวหน้า"))) {echo "checked";} ?> value="หัวหน้า" />
หัวหน้า
<input type="radio" name="R_position" <?php if (!(strcmp("$rs[R_position]","ผู้ร่วม"))) {echo "checked";} ?> value="ผู้ร่วม" />
ผู้ร่วม
จำนวน
<label>
<input name="persent" type="text" id="persent" value="<?=$rs['persent']; ?>" size="3" />
เปอร์เซ็นต์ </label></td>
</tr>
<tr bgcolor="#BFD0E6">
<td height="28" colspan="3" align="center" bgcolor="#FFFFFF"> </td>
</tr>
<tr bgcolor="#BFD0E6">
<td height="20" colspan="3" align="center" bgcolor="#FFFFFF">
<input type="submit" name="Submit" value=" บันทึกข้อมูล" class="button" style="cursor:pointer"/>
<input type="reset" value=" เคลียร์ข้อมูล" class="button" style="cursor:pointer"/>
<input type="button" value="ปิดหน้าต่าง" onclick="javascript:parent.close();" class="CURSOR-HAND" />
<input name="RecharId" type="hidden" id="RecharId" value="<? echo $rs["RecharId"];?>" />
<input name="Research_code" type="hidden" id="Recode" value="<? echo $_REQUEST["Research_code"];?>" />
</td>
</tr>
</table>
</form>
</label>
</fieldset>
</td>
</tr>
</table>
<?php
/** Free Resource */
$dbObj->freeresult($result);
/** Close the Database */
$dbObj->disconn();
/** Unset Class */
unset($dbObj);
?>
|