I've looked at examples for using a custom field in the grid on a list page. I'm using the following code to display links to related data in a custom field:
global $dal;
$value = "Journeys
";
$tblJourney = $dal->Table("tblJourney");
$rs = $tblJourney->Query("WorldID=".$data["WorldID"],"");
$rdata = db_fetch_array($rs);
while($rdata=db_fetch_array($rs))
{
$value = $value.("<a href=some_page.php?journey=".$rdata["JourneyID"].
">".$rdata["JourneyName"]."</a>
");
}
It sort of works. On the first row of the grid, it correctly displays links to 2 out of three records that should be returned. However, on the rest of the rows of the grid, it does not display any of the links that should be returned. Can anyone see something obvious in the code? Should I not use the DAL?