populating div layer when clicking link created from PHP data table?

  • Thread starter Thread starter Mr E
  • Start date Start date
M

Mr E

Guest
hello,

i have some PHP code that populates a div layer (currently not very well) with the picture of doors and then the name of the door next to it.

what i would like is to turn the text of the name of the door into a link which will display the price of the door in a new div layer (all the prices are stored in the same MySQL database) so users can buy the door if they want.

i can't figure out how to do it myself.

this is my code for people to look at


$result = mysql_query("SELECT DoorName, Thumbimage FROM tblpricelist WHERE DoorName like '%kenilworth%'");

echo "<table border='0'>
<tr>
</tr>";while($row = mysql_fetch_array($result))
{

echo "<th>". "<img src='". $row['Thumbimage']."' />";"</th>";

echo "<th>". $row['DoorName']; "</th>";
}
echo "</table>";
echo "<br />";
?>
</div>

<div id="doorprice">
<?php
echo "Click names to see prices";

?>


also if you can sort the conundrum of the doors and door named displaying in a nice way rather than just over flowing past the div layer
on and when you click on the door it displays the large version in a new window (again inside the link is in the same MySQL database)

i'd be eternally greatful to anyone who can figure out these problems, cause i'm stumped
 
Back
Top