like this....
(Very basic layout)
Statement page.....
PHP Code:
# incoming variable eg 'A'
$searchTerm= $_GET['q'];
$sql =mysql_query("select * from table where lastname like '$a%' order by lastname asc") or die(mysql_error());
while($row = mysql_fetch_assoc($sql)) {
echo '<a href="details.php?id='. $row['id'].'">'. $row['firstname'] . ' ' . $row['lastname'] .'</a><br>';
}
Details page....
PHP Code:
# incoming variable (ID) from url so use $_GET
$sql=mysql_query("select * from table where id=". mysql_real_escape_string($_GET['id'])) or die(mysql_error());
$row=mysql_fetch_assoc($sql);
echo $row['firstname'] . '<br>';
echo $row['lastname'] . '<br>';
# etc for other information
Mike
Bookmarks