dazzathedrummer Posted March 30, 2010 Share Posted March 30, 2010 Hi, I have a fairly simple list coming from a php/mysql query - I'd like to put a border around each record to make the list more readable. I'm having trouble with this - if I set 'border=1' in the table tag, obviously the border goes around the whole table - I've tried putting the table in a div, but that has the same effect. can anyone help me on this - i'm sure its quite simple, I just haven't got there yet. here's my php include table: - echo' <h1>Gigs</h1> <table width=\"605\" height=\"200\" >'; while($row = mysql_fetch_array($result, MYSQL_ASSOC)) {echo " <tr> <td style=\"height:80px; width:80px;\"valign=\"top\"> <img height=\"79px\" width=\"79px\" valign=\"top\" alt=\"calendarpic\" style=\"position:absolute; vertical-align:top; z-index:1;\" src=\"calpics/{$row['background']}.png\"/> <img height=\"79px\" width=\"79px\" valign=\"top\" alt=\"calendarpic1\" style=\"position:absolute; vertical-align:top; z-index:2;\" src=\"calpics/{$row['day']}.png\"/> <img height=\"79px\" width=\"79px\" valign=\"top\" alt=\"calendarpic2\" style=\"position:absolute; vertical-align:top; z-index:3;\" src=\"calpics/{$row['month']}.png\"/></td>". "<td colspan=\"3\"><font size=\"4\"><strong>{$row['gl_venue']}</td><td>{$row['gl_pf']}<br>{$row['gl_publish']}<br>{$row['gl_unavailable']}</td></tr>". "<tr><td width=\"495\" colspan=\"3\">{$row['gl_text']}</td></tr>". "<tr><td><b>Fee</td><td><strong>Phone</strong></td><td><b>Contact</td></tr>". "<tr><td>{$row['gl_net']}</td><td width=\"150px\">{$row['gl_phone']}</td><td>{$row['gl_contact']}</td></tr>". "<tr><td><strong>Comments</td></tr>". "<tr ><td height=\"20px\" colspan=\"3\">{$row['gl_comments']}</tr></td>". "<td colspan=\"2\"><a href=\"http://maps.google.co.uk/maps?f=q&source=s_q&hl=en&geocode=&q={$row['gl_postcode']}\">Click for map</a></td><td><input type=\"submit\" value=\"edit\"></td></tr>"; } echo '<tr style=\"height:40px\"></tr></tr></table><br><br>'; ?> Link to comment https://forums.phpfreaks.com/topic/196972-how-do-i-put-a-border-around-each-record-from-a-table-query/ Share on other sites More sharing options...
haku Posted March 30, 2010 Share Posted March 30, 2010 Please show us the HTML output from your PHP script. PHP has nothing to do with CSS. Link to comment https://forums.phpfreaks.com/topic/196972-how-do-i-put-a-border-around-each-record-from-a-table-query/#findComment-1034173 Share on other sites More sharing options...
dazzathedrummer Posted March 30, 2010 Author Share Posted March 30, 2010 Hi, sorry the result of the php is here:- http://www.the-guards.org.uk/private/giglist_private.php Link to comment https://forums.phpfreaks.com/topic/196972-how-do-i-put-a-border-around-each-record-from-a-table-query/#findComment-1034205 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.