function Showiconhover($id, $loaifile) { echo '<div class="itemhover">'; if (!isset($_SESSION['taikhoan'])) { echo '<a href = "download/' . $id . '.' . $loaifile . '" class ="content-hrefdown"></a>'; } else { $taikhoan = unserialize($_SESSION['taikhoan']); $idyeuthich = YeuThich::LayTaiLieuTheoTaiKhoan($taikhoan->ID); if (in_array($id, $idyeuthich)) { echo '<a href = "download/' . $id . '.' . $loaifile . '" class = "content-hrefdown"></a> <a href = "#" class = "content-hrefxoa"></a>'; } else { echo '<a href = "#" class = "content-hrefthem"></a> <a href = "download/' . $id . '.' . $loaifile . '" class = "content-hrefdown"></a>'; } } echo '</div>'; }
public static function XoaTaiLieuTheoTaiKhoan($idTaiKhoan) { BinhLuan::XoaTatCaTheoTaiKhoan($idTaiKhoan); YeuThich::XoaYeuThichTheoTaiKhoan($idTaiKhoan); $arrTaiLieu = TaiLieu::LayTaiLieuTheoTaiKhoan($idTaiKhoan); foreach ($arrTaiLieu as $value) { //echo $value->ID.'</br>'; static::XoaTaiLieu($value->ID); } }