as part of my tables I have table headers which can be clicked to be sorted
<a href="race_details.php?sort=HorseName&race=<? echo $race ?>&course=<?php echo $course ?>&date=<?php echo $date ?>">
as you can see the link uses information posted from the previous query.
Here
?sort=HorseName
is the column which will be the sort. How can I declare a function for the remainder of the code as that will be the same for the other headers
this bit
&race=<? echo $race ?>&course=<?php echo $course ?>&date=<?php echo $date ?>