<?php include "member/connect/config.php"; $strSQL = "SELECT * FROM member WHERE Username = '".mysql_real_escape_string($_GET["u"])."'"; $objQuery = mysql_query($strSQL) or die(mysql_error()); $objResult = mysql_fetch_array($objQuery); if(!$objResult) { header('Location: howto.php?u=siriyot'); } ?>
<?php include "member/connect/config.php"; $strSQL = "SELECT * FROM member WHERE Username = '".mysql_real_escape_string($_GET["u"])."'"; $objQuery = mysql_query($strSQL) or die(mysql_error()); $objResult = mysql_fetch_array($objQuery); if(!$objResult) { $uName = $objResult['name']; //เอาค่าที่ตรงการใส่ตัวแปร คุณก็ต้องแก้ตัวแปรเป็นของคุณด้วยนะ header('Location: howto.php?u=$uName'); } ?>
<?php include "member/connect/config.php"; $strSQL = "SELECT * FROM member WHERE Username = '".mysql_real_escape_string($_GET["u"])."'"; $objQuery = mysql_query($strSQL) or die(mysql_error()); $objResult = mysql_fetch_array($objQuery); if(!$objResult) { header('Location: index.php?u='.$_COOKIE["u"].''); } if($_COOKIE["u"] == "") { setcookie("u",$_GET["u"],time()+3600); } if(!$_COOKIE["u"]) { $uName = $objResult["Username"]; header('Location: index.php?u=$uName'); } ?>
<?php include "member/connect/config.php"; $strSQL = "SELECT * FROM member WHERE Username = ' ลองดูเงือนไขในการดีงข้อมูลตรงนี้ด้วย ' "; $objQuery = mysql_query($strSQL) or die(mysql_error()); $objResult = mysql_fetch_array($objQuery); $uName = $objResult["Username"]; if($objResult!=''){ header('Location: index.php?u=$uName'); } ?>
<?php include "member/connect/config.php"; $strSQL = "SELECT * FROM member WHERE Username = '".mysql_real_escape_string($_GET["u"])."'"; $objQuery = mysql_query($strSQL) or die(mysql_error()); $objResult = mysql_fetch_array($objQuery); $uName = $objResult["Username"]; //เอามาจากบรรทัดที่ 16 ทดสอบ echo ดู echo "ค่า uName :: ".$uName."<br>"; if(!$objResult) { header('Location: index.php?u='.$_COOKIE["u"].''); } if($_COOKIE["u"] == "") { setcookie("u",$_GET["u"],time()+3600); } if(!$_COOKIE["u"]) { header('Location: index.php?u=$uName'); } ?>
<?php include "member/connect/config.php"; $strSQL = "SELECT * FROM member WHERE Username = '".mysql_real_escape_string($_GET["u"])."'"; $objQuery = mysql_query($strSQL) or die(mysql_error()); $objResult = mysql_fetch_array($objQuery); if(!$objResult) { header('Location: test.php?u='.$User.''); } ?>
<?php // Database Connection $host="localhost"; // change $username = "root"; // change $password = "root"; // change $db="db"; // change $connect=mysql_connect($host,$username,$password) or die ("Cannot Connect to MySQL"); mysql_select_db($db) or die ("Cannot connect to Database"); //configwebsite $User = "siriyot"; // change ?>
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง