GetDepartureBoardByCRS(10,"BRI",date("H:i:s",time()),120,"","","","","True");
$template["header"] = "
ID |
Org. |
Dest. |
Plat. |
Sch |
Exp |
";
$template["row"] = "
{id} |
{org} |
{dest} |
{plat} |
{sch} |
{act} |
";
$template["footer"] = "
";
if (isset($response->GetBoardResult->trainServices->service))
{
print $template["header"];
foreach($response->GetBoardResult->trainServices->service as $service)
{
$row = $template["row"];
$destinations = array();
$row = str_replace("{id}",$service->trainid,$row);
$row = str_replace("{org}",$service->origin->location->tiploc,$row);
$row = str_replace("{dest}",$service->destination->location->tiploc,$row);
$row = str_replace("{plat}",$service->platform,$row);
$row = str_replace("{sch}",$servoce->std,$row);
$row = str_replace("{act}",$service->etd,$row);
print $row;
}
print $template["footer"];
}
?>