Hacked By AnonymousFox
<?
include"connect.php";
include("function.php");
include("register_global.php");
?>
<!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" />
<title>:: Application เก็บสถิติข้อมูลบุคลากร ::</title>
<link href="../register_thaimed/style.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
body {
background-color: #CCCCCC;
}
-->
</style>
<!-- import the calendar script -->
<link rel="stylesheet" type="text/css" href="../register_thaimed/myCalendarStyle.css">
<script type="text/javascript" src="../register_thaimed/calendar/lib/calendar.js"></script>
<script type="text/javascript" src="../register_thaimed/calendar/lib/lang/calendar-th.js"></script>
<script type="text/javascript" src="../register_thaimed/calendar/lib/loadcalendar.js"></script>
<style type="text/css">
<!--
.style31 { font-size: 16px;
font-weight: bold;
}
.style31 { font-size: 16px;
font-weight: bold;
}
.inputlogin {
background:#056839;
font-family:Tahoma, Geneva, sans-serif;
font-size:16px;
padding: 5px 10px 5px 10px;
color: #fff;
font-weight: bold;
-moz-border-radius: 6px;
-webkit-border-radius: 6px;
-moz-box-shadow: 0 1px 3px rgba(0,0,0,0.5);
-webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.5);
text-shadow: 0 -1px 1px rgba(0,0,0,0.25);
border-bottom: 1px solid rgba(0,0,0,0.25);
cursor: pointer;
border-left:none;
border-top:none;
margin:10px 0 10px 0;
}
-->
</style>
<script language="javascript">
function show_table(id) {
if(id == 1) { // ถ้าเลือก radio button 1 ให้โชว์ table 1 และ ซ่อน table 2
document.getElementById("table1").style.display = "";
document.getElementById("table2").style.display = "none";
} else if(id == 2) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("table1").style.display = "none";
document.getElementById("table2").style.display = "";
}else if(id == 3) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("table1").style.display = "none";
document.getElementById("table2").style.display = "";
}else if(id == 4) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("table1").style.display = "none";
document.getElementById("table2").style.display = "";
}
}
function show_table1(id) {
if(id == 1) { // ถ้าเลือก radio button 1 ให้โชว์ table 1 และ ซ่อน table 2
document.getElementById("tableo").style.display = "none";
} else if(id == 2) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("tableo").style.display = "none";
}else if(id == 3) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("tableo").style.display = "none";
}else if(id == 4) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("tableo").style.display = "";
document.getElementById('inputOther').focus();
}
}
function show_table3(id) {
if(id == 1) { // ถ้าเลือก radio button 1 ให้โชว์ table 1 และ ซ่อน table 2
document.getElementById("tableo1").style.display = "none";
} else if(id == 2) { // ถ้าเลือก radio button 2 ให้โชว์ table 2 และ ซ่อน table 1
document.getElementById("tableo1").style.display = "none";
}
}
function show_tableadd(id) {
if(id == 1) { // ถ้าเลือก radio button 1 ให้โชว์ table 1 และ ซ่อน table 2
document.getElementById("tableadd1").style.display = "none";
}
if(id == 2) { // ถ้าเลือก radio button 1 ให้โชว์ table 1 และ ซ่อน table 2
document.getElementById("tableadd1").style.display = "";
}
}
function CheckNum(){
if (event.keyCode < 48 || event.keyCode > 57){
event.returnValue = false;
}
}
</script>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="49%" height="100" align="right" bgcolor="#C6ECD9"><img src="logo.png" width="120" height="120" onclick="window.location='datalist.php'" style="cursor:pointer" /></td>
<td width="51%" align="left" bgcolor="#C6ECD9"><span class="style31"><strong>Application เก็บสถิติข้อมูลบุคลากร</strong></span></td>
</tr>
<tr>
<td colspan="2" align="center" valign="top" bgcolor="#B9CADA"><br />
<table width="98%" border="1" align="center" style="border-collapse:collapse" bordercolor="#8EADBF" cellpadding="10">
<tr>
<td width="83%" valign="top" bgcolor="#FFFFFF"><p>
<div align="center"><input type="submit" name="button22" id="button22" class="inputlogin" value="กลับหน้าหลัก" onclick="window.location='menu.php'" /></div>
</p>
<? ###################################################
if($action=="add") {
$sqlchk="insert into staff values (NULL,'$inputPrefix$inputOther','$inputfname','$inputsurname','$inputposition','$inputlevel','$inputgroup','$inputdept','$inputr$inputro')";
$querychk=mysql_query($sqlchk);
echo"<br />
<br />
<br />
<br /><table width=400 height=100 border=1 bordercolor=#C6ECD9 align=center cellpadding=0 cellspacing=0 bgcolor=#EFEFEF>
<tr>
<td height=100><div align=center><span class=table_footer style1><br>
ระบบได้บันทึกข้อมูลเรียบร้อยแล้ว</span><br>
<br />
<br />
<form id=form1 name=form1 method=post action=2.php>
<input type=image src=btn-submit.gif name=Image15112 width=57 height=20 border=0 id=Image15 style=cursor:pointer; />
</form>
<br>
</div></td>
</tr>
</table>"; ?><br />
<br />
<br />
<br /><? } else { ?>
<table border="1" bordercolor="#003300" style="border-collapse:collapse" width="90%" align="center" cellpadding="10" >
<form method="post" name="myForm" id="myForm" enctype="multipart/form-data" >
<input name="action" id="action" type="hidden" value="add" />
<tr>
<td colspan="2" valign="top" bgcolor="#C6ECD9"><div align="center"><strong><a href="1.php">บันทึกประวัติ</a></strong></div></td>
</tr>
<tr>
<td width="22%" valign="top"><div align="left">
<p><strong>คำนำหน้า</strong></p>
</div></td>
<td width="78%"><table border="0">
<tr>
<td><input name="inputPrefix" type="radio" value="1" onclick="show_table1(this.value);"/>
<span class="mytext_bold">นาย</span>
<input name="inputPrefix" type="radio" value="2" onclick="show_table1(this.value);"/>
<span class="mytext_bold">นางสาว</span>
<input name="inputPrefix" type="radio" value="3" onclick="show_table1(this.value);"/>
นาง
<input name="inputPrefix" type="radio" value="4" onclick="show_table1(this.value);"/>
อื่น ๆ</td>
<td align="left"><table width="100%" border="0" id="tableo" style="display:none">
<tr>
<td><input type="text" name="inputOther" id="inputOther" /></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
<tr>
<td><div align="left">
<p><strong>ชื่อ</strong></p>
</div></td>
<td><div align="left">
<input name="inputfname" type="text" id="inputfname" style="border:1px; padding:1px;border-style: solid ; border-color: #dbdee1;" maxlength="13" value="<?=$inputnation?>" />
</div></td>
</tr>
<tr>
<td><div align="left"><strong>นามสกุล</strong></div></td>
<td><div align="left">
<input name="inputsurname" type="text" id="inputsurname" style="border:1px; padding:1px;border-style: solid ; border-color: #dbdee1;" maxlength="13" value="<?=$inputnation?>" />
</div></td>
</tr>
<tr>
<td><div align="left"><strong>ตำแหน่ง</strong></div></td>
<td><input name="inputposition" type="text" id="inputposition" style="border:1px; padding:1px;border-style: solid ; border-color: #dbdee1;" maxlength="13" value="<?=$inputnation?>" /></td>
</tr>
<tr>
<td><div align="left"><strong>ระดับ</strong></div></td>
<td><input name="inputlevel" type="text" id="inputlevel" style="border:1px; padding:1px;border-style: solid ; border-color: #dbdee1;" maxlength="13" value="<?=$inputnation?>" /></td>
</tr>
<tr>
<td><div align="left"><strong>กลุ่มงาน</strong></div></td>
<td><input name="inputgroup" type="text" id="inputgroup" style="border:1px; padding:1px;border-style: solid ; border-color: #dbdee1;" maxlength="13" value="<?=$inputnation?>" /></td>
</tr>
<tr>
<td><div align="left"><strong>ฝ่าย</strong></div></td>
<td>
<input name="inputdept" type="text" id="inputdept" style="border:1px; padding:1px;border-style: solid ; border-color: #dbdee1;" maxlength="13" value="<?=$inputdept?>" />
</td>
</tr>
<tr>
<td><div align="left"><strong>สังกัดส่วนราชการ</strong></div></td>
<td><strong>
<script type="text/javascript">
function sSelect(){
index = document.getElementById('inputr').value;
if(index !='4'){
document.getElementById('inputro').style.display='none';
}
if(index =='4'){
document.getElementById('inputro').style.display='';
document.getElementById('inputro').focus();
}
}
</script>
<select name="inputr" id="inputr" onchange="sSelect()">
<option value="" selected="selected">- - เลือกส่วนราชการ - -</option>
<option value="โรงพยาบาลกลาง" selected="selected"> โรงพยาบาลกลาง </option>
<option value="โรงพยาบาลตากสิน"> โรงพยาบาลตากสิน </option>
<option value="โรงพยาบาลเจริญกรุงประชารักษ์"> โรงพยาบาลเจริญกรุงประชารักษ์ </option>
<option value="โรงพยาบาลหลวงพ่อทวีศักดิ์ ชุตินฺธโร อุทิศ"> โรงพยาบาลหลวงพ่อทวีศักดิ์ ชุตินฺธโร อุทิศ </option>
<option value="โรงพยาบาลเวชการุณย์รัศมิ์"> โรงพยาบาลเวชการุณย์รัศมิ์ </option>
<option value="โรงพยาบาลลาดกระบังกรุงเทพมหานคร"> โรงพยาบาลลาดกระบังกรุงเทพมหานคร </option>
<option value="โรงพยาบาลราชพิพัฒน์"> โรงพยาบาลราชพิพัฒน์ </option>
<option value="โรงพยาบาลสิรินธร"> โรงพยาบาลสิรินธร </option>
<option value="โรงพยาบาลผู้สูงอายุบางขุนเทียน"> โรงพยาบาลผู้สูงอายุบางขุนเทียน </option>
<option value="โรงพยาบาลบางนากรุงเทพมหานคร"> โรงพยาบาลบางนากรุงเทพมหานคร </option>
<option value="ศูนย์บริการการแพทย์ฉุกเฉินกรุงเทพมหานคร (ศูนย์เอราวัณ)"> ศูนย์บริการการแพทย์ฉุกเฉินกรุงเทพมหานคร (ศูนย์เอราวัณ) </option>
<option value="สำนักงานพัฒนาระบบบริการทางการแพทย์"> สำนักงานพัฒนาระบบบริการทางการแพทย์ </option>
<option value="4"> อื่น ๆ </option>
</select>
<input type="inputro" id="inputro" style="display:none" value="<?=$inputnation?>"/>
</strong></td>
</tr>
<tr>
<td colspan="2"><div align="center"><br />
<input type="submit" name="button2" id="button2" class="inputlogin" value="บันทึกข้อมูล">
<br />
<br />
</div></td>
</tr>
</form>
</table>
<? } ?>
</td>
</tr>
</table>
<br /></td>
</tr>
</table>
</body>
</html>
Hacked By AnonymousFox1.0, Coded By AnonymousFox