Hi,
I was wondering if anybody had any ideas how to structure this. I have a list of records that can be sorted by name, however, i want to put # - A -B - C - D - E.... etc... (all the letters of the alphabet) so that if the user clicks on "C" it shows everything the starts with "C", now my idea (but i dont think its the best way) was to have a $_GET for all the letters, like i said, does anybody have an easier way?
Thank you in advance
anybody have an idea
Moderator: General Moderators
put A-Z on your page or use one of the scripts here, then use this:
Code: Select all
<?php
$letter = trim(addslashes($_GET['letter']));
$query = "select * from `tablename` where `fieldname` LIKE '$letter%'";
?>