is formatting the table with css code I want to be able to change the table background. change the font size and color of Car Size and Image and other minor things.
any help is appreciated
/*note i am linking successfully to my external css sheet */
<?php
mysql_connect("localhost","user","blah") or die(mysql_error());// connect to the database
mysql_select_db("blah") or die(mysql_error()); // select database
$query = mysql_query("SELECT * FROM cars where carType = 'ford' AND active = 1") or die(mysql_error());
echo "<div id = 'tabledbs'>";
echo"<table border cellpadding = 3>";
if(mysql_num_rows($query) > 0){
echo"<tr><th>Car Name</th>
<th>Image</th</tr>";
while($row = mysql_fetch_array($query)){
/* Displays contents from database */
echo"<tr><td>" .$row['name'] . "</td>
<td><img src='".$row['imagePath'] ."'width='160' height='130'/></td></tr>";
echo "</div>";
}
}else{
echo "There are no cars to be displayed in the website;
}
?>
this is my attempt on my external css file
#tabledbs{background_color:black}
//would also like to change font size,colors,etc

New Topic/Question
Reply



MultiQuote




|