ABHIDHAMMAVIMUTTI :: TIPITAKA STUDIES AND DHAMMA PRACTICE BY BENZ THONGLOR
// set data
$cid=$cid;
// user require
require("connect.php");
mysql_connect($host,$uid,$pw) or die ("Unalbe to connect to SQL server");
mysql_select_db($db) or die ("Unable to select database");
//connect database
$sql = "select * from detail where cid=$cid ";
$result = mysql_query($sql) or die ("Can't Perform Query1");
// Language
if ($_SESSION["version"]=='thai') {
$txt_des = "descrip";
} Else {
$txt_des = "des_eng";
}
// show data loop
while($row=mysql_fetch_array($result)){
if ($row['dby']=='1' || $row['dby']=='') {
echo ("
");
echo "
";
if ($row[4]!=""){
echo "
";
echo "
$row[$txt_des]";
if (!empty($row[7])){
echo " $row[7]";
}
echo "
";
} else {
echo "
$row[$txt_des]";
if (!empty($row[7])){
echo " $row[7]";
}
echo "
";
}
echo "
";
echo "
";
}else {
echo ("
");
echo "
";
if ($row[4]!=""){
echo "
$row[$txt_des]";
if (!empty($row[7])){
echo " $row[7]";
}
echo "
";
echo "
";
} else {
echo "
$row[$txt_des]";
if (!empty($row[7])){
echo " $row[7]";
}
echo "