<?
$host="localhost";
$username="";
$pass_word="";
$db="test1";
$tb="pictrue";
$connect=mysql_connect( $host,$username,$pass_word) or die ("ติดต่อกับฐานข้อมูล Mysql ไม่ได้ ");
$select_db=mysql_select_db($db,$connect) or die("เลือกฐานข้อมูลไม่ได้");
$sql = "select * from picture where pic_id=1"; // หากต้องการดึงเฉพาะ Reccord ใด Record หนึ่ง ให้ใช้คำสั่ง where id='$ตัวแปร'
$result = mysql_query($sql) or die("ไม่สามารถ query ข้อมูลได้");
Parse error: parse error, unexpected '<', expecting ',' or ';' in c:\appserv\www\sample3.php on line 21
Date :
21 ก.ย. 2550 22:06:41
By :
ออฟ
No. 4
Guest
<?
$host="localhost";
$username="";
$pass_word="";
$db="test1";
$tb="pictrue";
$connect=mysql_connect( $host,$username,$pass_word) or die ("ติดต่อกับฐานข้อมูล Mysql ไม่ได้ ");
$select_db=mysql_select_db($db,$connect) or die("เลือกฐานข้อมูลไม่ได้");
$sql = "select * from picture where pic_id=1"; // หากต้องการดึงเฉพาะ Reccord ใด Record หนึ่ง ให้ใช้คำสั่ง where id='$ตัวแปร'
$result = mysql_query($sql) or die("ไม่สามารถ query ข้อมูลได้");