Bitrix Site Manager


 int type_id,
 string &by = "s_date",
 string &order = "desc",
 array max_min,
 array filter

The method GetDynamicList returns the number of events of the specified type, on daily basis.


Parameter Description
type_id The event type ID.
by Sorting field; possible values:
  • s_date - date.
order Sort order; the following values are possible:
  • asc - ascending;
  • desc - descending.
max_min Reference to an array containing minimum and maximum dates of the returned list. The array has the following structure:
    [DATE_FIRST] => minimum date
    [MIN_DAY] => day of the minimum date (1-31)
    [MIN_MONTH] => month of the minimum date (1-12)
    [MIN_YEAR] => year of the minimum date

    [DATE_LAST] => maximum date
    [MAX_DAY] => day of the maximum date (1-31)
    [MAX_MONTH] => month of the maximum date (1-12)
    [MAX_YEAR] => year of the maximum date
filter Array used to filter the resulting list. The following keys can be used in the array:
  • DATE1 - earliest date and time of the time period for which the information is to be returned;
  • DATE2 - latest date and time of the time period.

Structure of the returned record

    [DATE_STAT] => date
    [DAY] => day (1-31)
    [MONTH] => month (1-12)
    [YEAR] => year
    [COUNTER] => number of events of this type 
                 for the specified date

See Also


$type_id = 1;

// set the filter for December 2005
$arFilter = array(
    "DATE1" => "01.12.2005",
    "DATE2" => "31.12.2005"

// obtain the list of records
$rs = CStatEventType::GetDynamicList(

// print the date array
echo "<pre>"; print_r($arMaxMin); echo "</pre>";    

// print all records
while ($ar = $rs->Fetch())
    echo "<pre>"; print_r($ar); echo "</pre>";