case "noibat1": include "../../../BUS/TinDangBUS.php"; $aid = $_GET["idtin"]; TinDangBUS::setTinDangNoiBat($aid, 1); break; case "noibat0": include "../../../BUS/TinDangBUS.php"; $aid = $_GET["idtin"]; TinDangBUS::setTinDangNoiBat($aid, 0); break; case "status": include "../../../BUS/TinDangBUS.php"; include "../../../BUS/DichVuVIPBUS.php"; $aid = $_GET["aid"]; $status = $_GET["status"]; TinDangBUS::setStatusTinDang($aid, $status); if ($status == 2) { DichVuVIPBUS::SetStatusTinVIP($aid, 1); } break; } $tukhoa = isset($_REQUEST["tukhoa"]) ? $_REQUEST["tukhoa"] : -1; $loaidv = isset($_REQUEST["loaidv"]) ? $_REQUEST["loaidv"] : -1; $loainha = isset($_REQUEST["loainha"]) ? $_REQUEST["loainha"] : -1; $tinh = isset($_REQUEST["tinh"]) ? $_REQUEST["tinh"] : -1; $type = isset($_REQUEST["type"]) ? (int) $_REQUEST["type"] : -2; $aid = isset($_REQUEST["idtin"]) ? $_REQUEST["idtin"] : -1; $url = "index.php?view=article"; if ($tukhoa != -1) { $url .= "&tukhoa=" . $tukhoa; }
document.getElementById(objThis.id).style.color = "#B20751"; break; case 3: document.getElementById(objThis.id).style.color = "red"; break; } return false; } </script> <form method="post" name="frmListItem" id="frmListItem"> <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td width="30%"> <?php $listTinDang = TinDangBUS::GetAllTinDang(); if ($tukhoa != -1) { $listTemp = $listTinDang; $j = 0; for ($i = 0; $i < count($listTinDang); $i++) { $str1 = mb_strtolower($listTinDang[$i]["tieude"], 'UTF-8'); $str2 = mb_strtolower($tukhoa, 'UTF-8'); $index = strpos($str1, $str2) > -1 ? strpos($str1, $str2) : -1; if ($index > -1) { $listTemp[$j++] = $listTinDang[$i]; } } $listTinDang = $listTemp; for ($k = count($listTinDang) - 1; $k >= $j; $k--) { unset($listTinDang[$k]); }