Viewing file: Show_Edu_History.php (11.42 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" );
/** Create Database Object */
$dbObj = new DBConn;
/** Config Table for This Page */
$myTable = "personal_tb";
$myTable2 = "degree_his_tb";
$Username = $valid_user;
$query = " SELECT * FROM $myTable WHERE Username='$Username' ";
$result = $dbObj->execQuery($query);
$rs = $dbObj->fetchArray($result);
} # 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">
<!--
.style22 {font-size: 14px; font-weight: bold; }
-->
</style>
</head>
<body topmargin="0" rightmargin="0" bottommargin="0" leftmargin="0">
<?php
include("../templates/incHeader.php");
?>
<table width="997" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="189" align="left" valign="top" style="padding:10px 0px 0px 5px"><?php include("./_incMainMenu.php");?></td>
<td width="800" height="440" align="left" valign="top" style="padding:10px 0px 5px 10px"><fieldset>
<legend><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>"><a href="index.php">หน้าหลัก</a></font><img src="../picture/ico3.gif" width="10" height="10" align="absmiddle" border="0" /></font><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>"><a href="Menu_History.php?Teacher_code=<?=$Teacher_code;?>">ข้อมูลส่วนตัว</a></font><img src="../picture/ico3.gif" width="10" height="10" align="absmiddle" border="0" /></font><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>"><a href="Frm_Edit_Edu.php?Teacher_code=<?=$Teacher_code;?>">แก้ไขประวัติการศึกษา</a></font><img src="../picture/ico3.gif" width="10" height="10" align="absmiddle" border="0" /><span class="NOTE">ข้อมูลประวัติการศึกษา</strong></a></font></span></legend>
<table width="768" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="768" height="5"></td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td height="385" align="center" valign="top">
<table width="98%" border="0" align="center" cellpadding="1" cellspacing="1" bgcolor="#EEEEEE" style="border:0px solid gray">
<tr bordercolor="#E7FAFE" bgcolor="#E7FAFE">
<td width="112" height="20" align="right" nowrap="nowrap" bordercolor="#FFFFFF" bgcolor="#FFFFFF">วุฒิการศึกษาสูงสุด</td>
<td width="1" nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td width="628" nowrap="nowrap" bgcolor="#FFFFFF" class="TEXT-DARK-BLUE10"><?php
$Degree_code = $rs['Degree_code'];
$sql = " SELECT * FROM degree_tb WHERE Degree_code='$Degree_code' ";
$result4 = $dbObj->execQuery($sql);
$rs4 = $dbObj->fetchArray($result4);
$dbObj->freeresult($result4);
echo $rs4['Degree_name'];
?></td>
</tr>
<?php if( $rs["Degree_His1"] != "" ) { ?>
<tr bordercolor="#E7FAFE" bgcolor="#E7FAFE">
<td height="20" align="right" valign="top" nowrap="nowrap" bordercolor="#FFFFFF" bgcolor="#FFFFFF" class="PADDING-TOP-5">ปริญญาตรี</td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF" class="PADDING-TOP-3"><span class="TEXT-DARK-BLUE10"><?php echo htmlspecialchars_decode( nl2br( $rs['Degree_His1'] ) ); ?> <?php echo $rs['Degree_His1_Major']; ?> <?php echo $rs['Degree_His1_Institute']; ?> <?php echo $rs['Degree_His1_End_Year']; ?></span></td>
</tr>
<?php } #if ?>
<?php if( $rs["Degree_His2"] != "" ) { ?>
<tr bordercolor="#E7FAFE" bgcolor="#E7FAFE">
<td height="20" align="right" valign="top" nowrap="nowrap" bordercolor="#FFFFFF" bgcolor="#FFFFFF" class="PADDING-TOP-5">ปริญญาโท</td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF" class="PADDING-TOP-3"><span class="TEXT-DARK-BLUE10"><?php echo htmlspecialchars_decode( nl2br( $rs['Degree_His2'] ) ); ?> <?php echo $rs['Degree_His2_Major']; ?> <?php echo $rs['Degree_His2_Institute']; ?> <?php echo $rs['Degree_His2_End_Year']; ?></span></td>
</tr>
<?php } #if ?>
<?php if( $rs["Degree_His3"] != "" ) { ?>
<tr bordercolor="#E7FAFE" bgcolor="#E7FAFE">
<td height="20" align="right" valign="top" nowrap="nowrap" bordercolor="#FFFFFF" bgcolor="#FFFFFF" class="PADDING-TOP-5">ปริญญาเอก</td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF" class="PADDING-TOP-3"><span class="TEXT-DARK-BLUE10"><?php echo htmlspecialchars_decode( nl2br( $rs['Degree_His3'] ) ); ?> <?php echo $rs['Degree_His3_Major']; ?> <?php echo $rs['Degree_His3_Institute']; ?> <?php echo $rs['Degree_His3_End_Year']; ?></span></td>
</tr>
<?php } #if ?>
<tr bordercolor="#FFFFFF" bgcolor="#ECF5FF">
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
</tr>
<tr bordercolor="#FFFFFF" bgcolor="#ECF5FF">
<td colspan="3" nowrap="nowrap" bgcolor="#FFFFFF"><table width="99%" border="0" align="left" cellpadding="1" cellspacing="1" bgcolor="#FFFFFF" style="background-color:#eeeeee; border:0px solid gray">
<tr bgcolor="#F0F0F0">
<td height="25" colspan="7" align="left" bordercolor="#999966" bgcolor="#FFFFFF" class="PADDING-LEFT-10"><font color="#000000"><font size="2" face="Tahoma" ><a href="javascript:;" onclick="NewWindow('AddTeacherHis.php?Teacher_code=<?php echo $rs['Teacher_code']; ?>','Detail','scrollbars=yes,width=650,height=250')"><img src="../picture/new.gif" alt="เพิ่มรายการเอกสาร" width="16" height="16" border="0" /></a></font><font color="#000000"> <span class="style22"> เพิ่มวุฒิการศึกษา</span></font></font></td>
</tr>
<?php
$query = " SELECT * FROM $myTable2 WHERE Teacher_code='$Teacher_code' ";
$result1 = $dbObj->execQuery($query);
$numrows = $dbObj->_numrows;
?>
<?php
$no = 1+($display-1)*$limit;
while( $rss = $dbObj->fetchArray($result1) ) {
$bgColor = ( $bgColor == "#FFFFFF" ) ? "#F9FBFB" : "#FFFFFF";
?>
<tr bgcolor="<?=$bgColor;?>">
<td width="3%" height="20" align="right"><img src="../images/icons/linesub.gif" width="16" height="16" border="0" align="absmiddle" /></td>
<td width="10%" align="left" class="PADDING-LEFT-5"><?php
$Degree_code = $rss['Degree_code'] ;
$sql11 = " Select Degree_name From degree_tb Where Degree_code='$Degree_code' ";
$result11 = mysql_query($sql11);
$rs11 = mysql_fetch_array($result11);
echo"$rs11[Degree_name] ";
?></td>
<td width="37%" align="left" class="PADDING-LEFT-5"><? echo $rss['Degree_His'] ; ?> </font></a></td>
<td width="30%" align="left" class="PADDING-LEFT-5"><font color="#000000" size="2" face="Tahoma"><? echo $rss['Degree_Major']?></font></td>
<td width="13%" align="left" class="PADDING-LEFT-5"><font color="#000000" size="2" face="Tahoma"><font color="#000000" size="2" face="Tahoma"><? echo $rss[Degree_Year]?></font></font></td>
<td width="3%" align="center" class="PADDING-LEFT-5"><font size="2" face="Tahoma"><a href="javascript:;" onclick="NewWindow('FrmTeacherHis.php?DegreeId=<? echo $rss['DegreeId']?>','Detail','550','300','yes');"><img src="../images/icons/icon-edit.gif" alt="แก้ไขข้อมูล" width="16" height="16" border="0" /></a></font></td>
<td width="4%" align="center" class="PADDING-LEFT-5"><div align="center"><strong><font size="2" face="Tahoma">
<script language="JavaScript" type="text/javascript">
function Conf<?=$rss[DegreeId];?>0(object) {
if (confirm("คุณต้องการลบข้อมูล <?php echo " $rss[DegreeId]"; ?> หรือไม่?") == true) {
return true;
}
return false;
}
</script>
<a href="DelTeacherHis.php?DegreeId=<?php echo $rss['DegreeId']; ?>&Teacher_code=<?php echo $rss['Teacher_code'];?>"> <img src="../images/icons/cross.png" width="16" height="16" align="absmiddle" border="0" onclick="return Conf<?=$rss[DegreeId];?>0(this)" alt="ลบข้อมูล" /></a></font></strong></div></td>
</tr>
<?php
//$no++;
} # while
?>
<tr>
<td height="22" colspan="7" align="center" bgcolor="#F8F8F8"><strong>ทั้งหมด <span class="NOTE"><?php echo $numrows; ?></span> รายการ</strong></td>
</tr>
</table></td>
</tr>
<tr bordercolor="#FFFFFF" bgcolor="#ECF5FF">
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF"> </td>
</tr>
<tr bordercolor="#FFFFFF" bgcolor="#ECF5FF">
<td nowrap="nowrap" bgcolor="#FFFFFF" align="center"> </td>
<td nowrap="nowrap" bgcolor="#FFFFFF" align="center"> </td>
<td height="30" align="center" nowrap="nowrap" bgcolor="#FFFFFF"> </td>
</tr>
</table> </td>
</tr>
</table>
</fieldset></td>
</tr>
</table>
<?php include("../templates/incFooter.php"); ?>
</body>
</html>
<?php
/** Free Resource */
$dbObj->freeresult($result);
/** Close the Database */
$dbObj->disconn();
/** Unset Class */
unset($dbObj);
?>
|