<?php
/*--------------------------------------------------------- 
 * File:advers.php
 * Author:Tomix
 * Description: 
 * Created:2009
 * -------------------------------------------------------
 * Modified history:2023/08/23
 * Copyright © 2023 蘋果世界股份有限公司 版權所有
 * -------------------------------------------------------
 */
require_once dirname(__FILE__)."/../dal/adverDAL.php";
class advers {
    private static $dal;

    // 根据广告栏目取得广告信息集合
    public static function getAdvers($categoryId, $length = -1) {
        if (!isset(self::$dal)) self::$dal = new adverDAL();

        $filter = "a.CategoryID='" . $categoryId . "' AND a.Visible=1";
        return self::$dal->executeRecordset($filter, 0, $length);
    }
}
?>
