<?
$objConnect = mysql_connect("localhost","root","root") or die("Error Connect to Database");
$objDB = mysql_select_db("project");
mysql_query("SET NAMES UTF8");
if($_GET["search"] ==1)
{
$strSQL = "SELECT * FROM project WHERE (PDNAMET LIKE '%".$_GET["txtKeyword"]."%' or SITENO LIKE '%".$_GET["txtKeyword"]."%')";
$objQuery = mysql_query($strSQL) or die ("Error Query [".$strSQL."]");
}
elseif($_GET["search"] ==2)
{
$strSQL = "SELECT * FROM project WHERE (PDNAMET LIKE '%".$_GET["txtKeyword"]."%' )";
$objQuery = mysql_query($strSQL) or die ("Error Query [".$strSQL."]");
}
elseif($_GET["search"] ==3)
{
$strSQL = "SELECT * FROM detail WHERE (SITENO LIKE '%".$_GET["txtKeyword"]."%' )";
$objQuery = mysql_query($strSQL) or die ("Error Query [".$strSQL."]");
}
?>