HTML question ( was: "MySQL help ")
Posted: Sat Sep 06, 2008 3:06 pm
Moved from MySQL. This is stricly an HTML question.
My code:
It out puts Somthing that looks like this... what i need help with is explained in the pic:

My code:
Code: Select all
<?php
mysql_connect("localhost", "root", "") or die(mysql_error());
mysql_select_db("fof") or die(mysql_error());
$Song = mysql_query("SELECT * FROM `songs` WHERE `Artist` LIKE CONVERT( _utf8 '%$Artist2%' USING latin1 ) COLLATE latin1_swedish_ci AND `Album` LIKE CONVERT( _utf8 '%$Album2%' USING latin1 ) COLLATE latin1_swedish_ci") or die(mysql_error());
while($row = mysql_fetch_array( $Song )) {
$Artist2 = $row['Artist'];
$Album2 = $row['Album'];
echo" <table border='1' cellspacing='0' cellpadding='0'>";
echo" <tr><th colspan='2'>";
echo $row['Artist'];
echo" </th></tr>";
echo" <tr>";
echo" <td valign='top' style='text-align: center; width: 160px; padding-top: 10px; padding-bottom: 10px;'>";
echo" <div style='padding: 8px; font: 12px arial; font-weight: bold;'>";
echo $row['Album'];
echo" <br />";
echo $row['Artist'];
echo" </div>";
echo" </td>";
echo" <td valign='top'>";
echo" <table border='1' style='width: 100%; margin-top: 10px; margin-bottom: 10px;' cellpadding='0' cellspacing='0'>";
echo" <tr>";
echo" <td width='8' style='font-weight: bold;text-align: right; width: 6px;'>";
echo $row['TRACK'];
echo" </td>";
echo" <td width='96'>";
echo $row['Song'];
echo" </td>";
echo" <td width='46' style=' border-left: 1px #cccccc solid; width: 40px;'>";
echo $row['TIME'];
echo" </td>";
echo" </tr>";
echo" </table>";
echo" </td>";
echo" </tr>";
echo" </table>";
}
?>