<? session_start(); if (session_is_registered("valid_uname") && session_is_registered("valid_pwd")) { ?> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <style type="text/css"> <!-- .style1 { font-family: "TH SarabunPSK"; font-size: 18pt; font-weight: bold; } .style2 { font-family: "TH SarabunPSK"; font-size: 16pt; font-weight: bold; } .style3 { font-family: "TH SarabunPSK"; font-size: 14pt; } .style5 {cursor: hand; font-weight: normal; color: #000000;} .style9 {font-family: Tahoma; font-size: 12px; } .style11 {font-size: 12px} .style13 {font-size: 9} .style16 {font-size: 9; font-weight: bold; } .style17 {font-size: 12px; font-weight: bold; } .style12 { font-family: Tahoma; font-size: 12px; } --> </style> <? // เชื่่อมต่อฐานข้อมูล $host="localhost"; // กำหนด host $username="root"; // กำหนด username $pass_word="admin"; // กำหนด Password $db="db_dss"; // กำหนดชื่อฐานข้อมูล $Conn = mysql_connect( $host,$username,$pass_word) or die ("ติดต่อฐานข้อมูลไม่ได้");// ติดต่อฐานข้อมูล mysql_query("SET NAMES UTF8",$Conn); // set กำหนดมาตราฐาน mysql_select_db($db) or die("เลือกฐานข้อมูลไม่ได้"); // เลือกฐานข้อมูล //---> ?> <table align="center"width="200" border="0"> <tr> <td><? require("head.php");?> </td> </tr> <tr> <td align="center"><table width="1121" height="55" border="1" cellpadding="0" cellspacing="0"> <tr> <td width="138" height="32" class="style2"><div align="center">รหัสสมาชิก</div></td> <td class="style2" width="135"><div align="center">Username</div></td> <td class="style2" width="254"><div align="center">ชื่อ-นามสกุล</div></td> <td class="style2" width="149"><div align ="center">อีเมล์</div></td> <td class="style2" width="122"><div align="center">โทรศัพท์</div></td> <td class="style2"width="153"><div align="center">แก้ไข</div></td> <td align="center" class="style2"width="154">ลบ</td> </tr> <? $sql_show = "select * from tbmember"; $result_show = mysql_query($sql_show) or die(mysql_error()); while($row_show = mysql_fetch_array($result_show)) { ?> <tr> <td height="21" align="center"><?=$row_show['MemberID']?></td> <td align="center"><?=$row_show['Username']?></td> <td align="center"><?=$row_show['Name']?></td> <td align="center"><?=$row_show['Email']?></td> <td align="center"><?=$row_show['Phone']?></td> <td align="center" class="style2"><div align="center"><a href="memberedit.php?edit_id=<?=$row_show[MemberID]?>">แก้ไข</a></div></td> <td align="center" class="style2"><a href="member_del.php?edit_id=<?=$row_show[MemberID]?> "onclick="return confirm('คุณแน่ใจที่จะลบหรือไม่?')">ลบ</a></td> </tr> <? } ?> </table> <table width="250" border="0" align="right" cellpadding="0" cellspacing="0"> <tr> <td align="right"><a href="menu_member.php"><img src="picture/back.gif" width="250" height="80" /></a></td> </tr> </table> <p> </p> </td> </tr> <tr> <td><? require("footer.php");?></td> </tr> </table> <? } else{ echo"<script language ='JavaScript'>"; echo"alert('Please Login');"; echo"</script>"; echo "<meta http-equiv='refresh' content='0;url=index.php' />"; exit(); } ?>
<?PHP $sql_show = "select * from tbmember"; $result_show = mysql_query($sql_show) or die(mysql_error()); $no = 1; while($row_show = mysql_fetch_array($result_show)) { ?> <tr> <td height="21" align="center"><?=$no?></td> <td align="center"><?=$row_show['Username']?></td> <td align="center"><?=$row_show['Name']?></td> <td align="center"><?=$row_show['Email']?></td> <td align="center"><?=$row_show['Phone']?></td> <td align="center" class="style2"><div align="center"><a href="memberedit.php?edit_id=<?=$row_show[MemberID]?>">แก้ไข</a></div></td> <td align="center" class="style2"><a href="member_del.php?edit_id=<?=$row_show[MemberID]?> "onclick="return confirm('คุณแน่ใจที่จะลบหรือไม่?')">ลบ</a></td> </tr> <?PHP ++$no;} ?>
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง