mgd_list_events

Name

mgd_list_events -- List event records

Synopsis

object mgd_list_events(int id, string [sort], int [type]);

Description

Minimum version: Midgard 1.4 (Bifrost)

Lists the events that have their up field set to id

The optional parameter sort is used to sort the events, and can be one of: "alpha", "reverse alpha" (which will sort by title) ; "start", "reverse start" ; "end", "reverse end", Default sort is by created date.

Returns an object traversable by calling fetch if successfull. Returns false on failure.

Example

<?php
  $list = mgd_list_events(17);
  while($list->fetch()) {
    echo $list->title . "<br>\n";
  }
?>