Okay I have now changed my code to the following
<?
$db = mysql_connect("localhost","username","password");
mysql_select_db ("databasename");
$q = mysql_query("show tables");
while ($row = mysql_fetch_row($q)) {
echo "<a href=details_test2.php?lang=en-iso-8859-1&server=1&db=databasename&table=$row[0]>$row[0]</A><br>";
}
{
mysql_close($db);
}
?>
Now this code does create a link and seems to be selecting the proper table, I think but the results still do not show the choosen table on the details page. may be I need to change my content source code at the top of the details page?
Currently it looks like this
<?php // GoLive Content Source
$Tickets = WrapMySQLDatabaseResults("ticketwizard", "select * from Master_Table where TicketLevel like '%" . pageParameter("TicketLevel","") . "%' and TicketSection like '%" . pageParameter("TicketSection","") . "%' and TicketRow like '%" . pageParameter("TicketRow","") . "%' and TicketSeat like '%" . pageParameter("TicketSeat","") . "%' and TicketStatus like '%" . pageParameter("TicketStatus","") . "%' and TicketFName like '%" . pageParameter("TicketFName","") . "%' and TicketLName like '%" . pageParameter("TicketLName","") . "%'", "block=20","Tickets");
?>
This code only returns the details of all records in the Master_Table.
How would I replace the Master_Table in the "select * from Master_Table where" clause to be a variable. So when a link from the table list is clicked it will retrieve records from the right table?