CAdvBanner :: GetWeekdayArray: Bitrix method

      
<?php 
//  CAdvBanner :: GetWeekdayArray()
//  /dist/bitrix/modules/advertising/classes/general/advertising.php:1679

    
public static function GetWeekdayArray($BANNER_ID)
    {
        
$err_mess = (CAdvBanner_all::err_mess())."<br>Function: GetWeekdayArray<br>Line: ";
        global 
$DB;
        
$BANNER_ID intval($BANNER_ID);
        if (
$BANNER_ID<=0)
            return 
false;
        
$arrRes = array();
        
$strSql "
            SELECT DISTINCT
                C_WEEKDAY,
                C_HOUR
            FROM
                b_adv_banner_2_weekday
            WHERE
                BANNER_ID = 
$BANNER_ID
            "
;
        
$rs $DB->Query($strSqlfalse$err_mess.__LINE__);
        while (
$ar $rs->Fetch())
            
$arrRes[$ar["C_WEEKDAY"]][] = $ar["C_HOUR"];
        return 
$arrRes;
    }