public static function findBussiness() { //create string sql //if(isset($_REQUEST['btnSearch'])) //{ $strLink = "dichvu.php?"; $strSQL = "select * from "; $strTable = "dichvu"; $strWhere = " where status>0 "; if (isset($_REQUEST['cbbLoaidv']) && $_REQUEST['cbbLoaidv'] != -1) { $strLink .= "cbbLoaidv=" . $_REQUEST['cbbLoaidv'] . "&"; $strWhere .= " and dichvu.loaidv=" . $_REQUEST['cbbLoaidv']; } if (isset($_REQUEST['cbbLoaiBDS']) && $_REQUEST['cbbLoaiBDS'] != -1) { $strLink .= "cbbLoaiBDS=" . $_REQUEST['cbbLoaiBDS'] . "&"; $strWhere .= " and dichvu.loainha=" . $_REQUEST['cbbLoaiBDS']; } if (isset($_REQUEST['cbbTinh']) && $_REQUEST['cbbTinh'] != -1) { $strLink .= "cbbTinh=" . $_REQUEST['cbbTinh'] . "&"; $strWhere .= " and dichvu.tinh=" . $_REQUEST['cbbTinh']; } if (isset($_REQUEST['cbbQuanHuyen']) && $_REQUEST['cbbQuanHuyen'] != -1) { $strLink .= "cbbQuanHuyen=" . $_REQUEST['cbbQuanHuyen'] . "&"; $strWhere .= " and dichvu.quan=" . $_REQUEST['cbbQuanHuyen']; } $strSQL .= $strTable . $strWhere . " order by status desc"; return BusinessProcessor::findBusiness($strLink, $strSQL); //} //return null; }