<!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=utf-8" /> <title>form_login</title> </head> <body> <form id="form3" name="form3" method="post" action="login_confirm.php"> <table width="200" border="1"> <tr> <td><table width="186" border="0" cellpadding="1"> <tr> <td colspan="2"><img src="Images/bar/bar_login01.gif" alt="" width="187" height="33" /></td> </tr> <tr> <td width="59">username</td> <td width="120"><input name="id" type="text" id="id" size="14" maxlength="14" /></td> </tr> <tr> <td>password</td> <td><input name="pass" type="text" id="pass" size="14" maxlength="14" /></td> </tr> <tr> <td colspan="2"><center> <label> <select name="select" id="select"> <option selected="selected">--เลือกรายการ--</option> <option>เจ้าหน้าที่</option> <option>นักศึกษา</option> </select> </label> <label> <br /> <br /> <input name="button" type="submit" id="button" value="Login" /> </label> </center> <br /></td> </tr> </table></td> </tr> </table> </form> </body> </html>
<? session_start();?> <!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=utf-8" /> <title>confirm_login</title> </head> <body> <? include('function.php'); include("connect.php"); checknull($_POST[id],"username"); switch($_POST[id]){ case ('admin'): checknull($_POST[pw],"password"); $_SESSION[id]=$_POST[id]; $sql=mysql_query("select pass from admin where pass='$_POST[pw]'")or die(mysql_error()); $num=mysql_num_rows($sql); if($num>0){ echo '<meta http-equiv="Refresh" content="0;URL=index.php">';} else{ echo '<center><br><br><br><br><img src="Images/logo.jpg" width="252" height="74" /></center>'; echo '<br><br><center><font size=2 color=red><b>รหัสผ่านไม่ถูกต้องครับ</b></font></center><br><br>'; ?> <center><input type="button" value="ย้อนกลับ" onClick="history.back()" /></center> <? die(); } } break; default : // มันerror ตรงนี้นะครับ ?> </body> </html>
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง