<?
  include('../functions.php');

  $startDate="2009-10-05";
  $endDate="2009-10-12";
  $u18 = true;
  $self = false; # Selbstanmeldung

  # Create Application Object
  $healthmiles = new healthmiles();
 
  # Fetch all users with changes in balance between startDate and endDate
  $userIds = $healthmiles->getRegistrations($startDate,$endDate,$u18,$self);

  # iterate through result list
  foreach($userIds as $userId) {
      print "--------------------------------------------------------\n";

      # create user object
      $user = new user(0,$userId);
      print $user->vorname . ', ' .  $user->name . ', ' .  $user->geburtsdatum . ', ' . $user->land . ', ' .
      date("Y-m-d", $user->erstellungsdatum ) . "\n";
  }
  print "Anzahl: " . sizeof($userIds) . "\n";
?>
