<?php $string = "This is a test"; $key1 = "is"; $key2 = "a"; echo ereg_replace("($key1)", "<font color=\"red\">$key1</font>", $string)."<br>"; ?>
<? if($_GET["txtKeyword"]!= "") { $keyword = explode(" ", $_GET["txtKeyword"]); for($h= 0; $h < count ($keyword); $h++){ } $strSQL ="SELECT * FROM table1 WHERE (ThaiName LIKE '%".$keyword[0]."%')";
<?php $string = "This is a test"; $key1 = "is"; $key2 = "a"; $string= ereg_replace("($key1)", "<font color=\"red\">$key1 </font>", $string)."<br>"; echo ereg_replace("($key2)", "<font color=\"red\">$key2 </font>", $string)."<br>"; ?>
<?php $string = "This is a test"; $key1 = "is"; $key2 = "a ก่อนทอ้งฟ้า"; $x1 = $string.$key1.$key2; echo "<font color=\"red\">$x1</font><br>"; if(strpos( $x1,"ก่อน") != "") { echo "เจอตัวที่ต้องการ"; } else {echo "ไม่มีตัวที่ต้องการ";} ?>
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง