$strSQL = "SELECT data_user.*,data_car.*,data_prb.*,data_ins.* FROM data_user
left JOIN data_car on data_user.id=data_car.car_id
left JOIN data_prb on data_user.id=data_prb.prb_id
left join data_ins on data_user.id=data_ins.ins_id
WHERE 1 AND data_user.member_id = '$_SESSION[login_true]'
ORDER BY id DESC";
if($_POST["ddlSelect"] != "" and $_POST["txtKeyword"] != '')
{
$strSQL .= " AND (".$_POST["ddlSelect"]." LIKE '%".$_POST["txtKeyword"]."%' ) ";
}
$objQuery = mysql_query($strSQL) or die ("Error Query [".$strSQL."]");
?>
<?php
while($objResult = mysql_fetch_array($objQuery))
{
?>