Viewing file: EditPosition.php (9.31 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") && !session_is_registered("Priority") ) {
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( "../include/Function.php" );
/** Chart */
/** Create Database Object */
$dbObj = new DBConn;
$sql = " SELECT * FROM personal_tb WHERE Teacher_code='$Teacher_code' ";
$result = mysql_query($sql);
$rss = mysql_fetch_array($result);
$sql2 ="Select * From history_position_tb Where code='$code'";
$result2 = mysql_query($sql2) or die(" Error").mysql_error();
$rs = mysql_fetch_array($result2);
} # else
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874" />
<link href="../css/default.css" rel="stylesheet" type="text/css" />
<script language="javascript" src="../js/utilities.js"></script>
<title>ข้อมูลการพัฒนาบุคลากร - ประวัติการรับพระราชทานเครื่องราชอิสริยาภรณ์บุคลากรทั้งหมด</title>
<style type="text/css">
<!--
.style4 { font-family: Tahoma;
font-size: 14px;
}
.style5 {font-size: 14px}
-->
</style>
</head>
<body topmargin="0" rightmargin="0" bottommargin="0" leftmargin="0">
<br />
<table width="624" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="624" height="229"><fieldset>
<form id="form1" name="form1" method="post" action="EditPositionSave.php">
<br />
<table width="92%" border="0" align="center" cellpadding="0" cellspacing="1" style="background-color:#eeeeee; border:0px solid gray"size="12">
<tr bgcolor="#D9ECFF">
<td height="25" colspan="3" bgcolor="#FFFFFF"><div align="center"><font color="#999999" face="Tahoma"><strong><span class="style5"><font color="#CC0000">แก้ไข</font><font color="#000000"> ข้อมูลประวัติการดำรงตำแหน่ง</font></span></strong></font></div></td>
</tr>
<tr bgcolor="#eeeeee">
<td width="30%" height="24" bordercolor="#CCCCCC" bgcolor="#FFFFFF"><div align="center"><font size="2" face="Tahoma">วัน/เดือน/ปีที่ดำรงตำแหน่ง</font></div></td>
<td width="1%" bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td width="69%" bordercolor="#FFFFCC" bgcolor="#FFFFFF"><font color="#000000" size="2" face="Tahoma">วันที่
<select name="mDate" id="mDate" class="select" >
<?php
$Date_post = $rs[Date_post];
$yearthai = explode("-",$Date_post);
$mDate = intval($yearthai[2]);
$mMonth = intval($yearthai[1]);
$mYear = intval($yearthai[0]);
for($i=0;$i<=31;$i++)
{
if( $i == 0)
echo"\n\t<option value=\"$mDate\" selected>$mDate</option>\n ";
else
echo"\n\t<option value=\"$i\">$i</option>\n ";
}
// getDay1to31();
?>
</select>
เดือน
<select name="mMonth" id="select2" class="select" >
<?php
$Date_post = $rs[Date_post];
$yearthai = explode("-",$Date_post);
$mDate= intval($yearthai[2]);
$Month = intval($yearthai[1]);
$mYear = intval($yearthai[0]);
$mMonth = $Month;
$CMonth = TxtThaiMonth($Month);
for($i=-1;$i<=11;$i++)
{
$a = $i+1;
if( $a == 0)
echo"\n\t<option value=\"$mMonth\" selected>$CMonth</option>\n ";
else
echo"\n\t<option value=\"$a\">$ThaiMonth[$i]</option>\n ";
}
// getThaiMonth();
?>
</select>
ปี พ.ศ.
<input name="mYear" type="text" class="style5" id="mYear" value="<? echo $mYear ?>" size="5" maxlength="4" />
</font></td>
</tr>
<tr bgcolor="#eeeeee">
<td bordercolor="#CCCCCC" bgcolor="#FFFFFF"><div align="center"><font size="2" face="Tahoma">เลขที่ตำแหน่ง</font></div></td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><input name="Position_id" type="text" class="style5" id="Position_id" value="<? echo $rs[Position_id]?>" size="30" /></td>
</tr>
<tr bgcolor="#eeeeee">
<td bordercolor="#CCCCCC" bgcolor="#FFFFFF"><div align="center"><font size="2" face="Tahoma">ตำแหน่ง</font></div></td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><input name="Gover_pos" type="text" class="style5" id="Gover_pos" value="<? echo $rs[Gover_pos]?>" size="40" />
<font size="2" face="Tahoma">ระดับ
<input name="Level" type="text" class="style5" id="Level" value="<? echo $rs[Level]?>" size="1" maxlength="2" />
</font></td>
</tr>
<tr bgcolor="#eeeeee">
<td bordercolor="#CCCCCC" bgcolor="#FFFFFF"><div align="center"><font size="2" face="Tahoma">เงินเดือน</font></div></td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><font size="2" face="Tahoma">
<input name="Salary" type="text" class="style5" id="Salary" value="<? echo $rs[Salary]?>" size="10" />
บาท <font color="#FF0000">(ไม่ต้องใส่เครื่องหมาย , )</font></font></td>
</tr>
<tr bgcolor="#eeeeee">
<td align="center" bordercolor="#CCCCCC" bgcolor="#FFFFFF">เงินค่าตอบแทน ตำแหน่ง</td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><input name="Salary_2" type="text" id="Salary_2" value="<? echo $rs[Salary_2]?>" size="10" class="style4" /></td>
</tr>
<tr bgcolor="#eeeeee">
<td align="center" bordercolor="#CCCCCC" bgcolor="#FFFFFF">เงินประจำตำแหน่ง</td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><input name="Salary_3" type="text" class="style4" id="Salary_3" value="<? echo $rs[Salary_3]?>" size="10" /></td>
</tr>
<tr bgcolor="#eeeeee">
<td align="center" bordercolor="#CCCCCC" bgcolor="#FFFFFF"><font face="Tahoma">เลขที่/คำสั่ง</font></td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><textarea name="Order_id" cols="45" id="Order_id"><? echo $rs[Order_id]?></textarea></td>
</tr>
<tr bgcolor="#eeeeee">
<td bordercolor="#CCCCCC" bgcolor="#FFFFFF"><div align="center"><font size="2" face="Tahoma">สถานะเงินเดือนปัจจุบัน</font></div></td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"> </td>
<td bordercolor="#FFFFCC" bgcolor="#FFFFFF"><p><font size="2" face="Tahoma">
<input type="radio" name="Flag" <?php if (!(strcmp("$rs[Flag]","Y"))){echo "checked";} ?> value="Y" />
</font>ใช้
<font size="2" face="Tahoma">
<input type="radio" name="Flag" <?php if (!(strcmp("$rs[Flag]","N"))){echo "checked";} ?> value="N" />
</font> ไม่ใช้
</p></td>
</tr>
<tr bgcolor="#D9ECFF">
<td colspan="3" bgcolor="#FFFFFF"><div align="center">
<input type="hidden" name="Teacher_code" value="<? echo $rs[Teacher_code]?>" />
<input type="hidden" name="code" value="<? echo $rs[code]?>" />
<input name="Submit" type="submit" class="WIDTH60" id="Submit2" value="บันทึก" />
<input name="Reset" type="reset" class="WIDTH60" id="Reset" value="Reset" />
<input type="button" name="Submit" value="ปิดหน้าต่าง" onclick="javascript:parent.close();" class="CURSOR-HAND" id="Submit" />
</div></td>
</tr>
</table>
<p> </p>
</form>
</label>
</fieldset>
<font color="<?php echo $GLOBALS["COLOR_FONT_3"];?>" size="2"> </font></td>
</tr>
</table>
</body>
</html>
<?php
/** Free Resource */
$dbObj->freeresult($result);
/** Close the Database */
$dbObj->disconn();
/** Unset Class */
unset($dbObj);
?>
|