Hello one and all,
**//'$initial' is a letter of the alphabet got from the previous script
<?php require_once('../Connections/seaman.inc.php'); ?>
<?php
mysql_select_db($database_surname, $seaman);
$query_Recordset1 = "SELECT surname.surname
FROM surname
WHERE left(surname.surname,1)='$initial'
GROUP BY surname.surname
ORDER BY surname.surname";
$Recordset1 = mysql_query($query_Recordset1, $seaman) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?>
<?php do { ?>
<a href="details.php?surname=<?php print $row_Recordset1['surname']; ?>"
<?php echo $row_Recordset1['surname']; ?>
<?php } while ($row_Recordset1 = mysql_fetch_assoc($Recordset1)); ?>
<?php mysql_free_result($Recordset1); ?>
I know this can be written as one <?php-?> but it make life easier while testing.
The above script works but as I have 12000 names of sailors that died in the Great War it makes very long single list of the letter "M" names. You have to scroll down for ever.
How do I make it spread over the page in rows of 4 or 5 and stop when 60 names are visiable and then continue to the next page.
Can I do it using PHP or do I have to use HTML?
All idea's are welcome.
greetings from The Netherlands
Liam