Hello i am having a weird problem can you help me please , my code belov is php , but my problem in it is css , if u have a look i would appreciate it…
[code=php]function lastfivegames($country_id,$team_id)
{
$result=mysql_query(“SELECT home_id AS h, away_id AS a, home_score AS hscr,away_score AS ascr, week_no, country_id
FROM results where
country_id = $country_id and (home_id=$team_id or away_id=$team_id)
“);
echo “<table width=’300′ border=’1′ >”;
$counter=0;
while($row = mysql_fetch_array($result)){
if($counter>4)
{
break;
}
$counter++;
if($row[“hscr”]>$row[“ascr”])
{
$baran2=’relegate’;
$baran1=’chlig’;
}
if($row[“hscr”]<$row[“ascr”])
{
$baran1=’relegate’;
$baran2=’chlig’;
}
if($row[“hscr”]==$row[“ascr”])
{
$baran1=’default’;
$baran2=’default’;
}
echo ‘<tr>’;
echo “<td wıdth=’138′ align=’right’ class=’$baran1′>”;
$home=$row[“h”];
$away=$row[“a”];
$result2=mysql_query(“select name from teams where team_id=$home”);
$row2 = mysql_fetch_array($result2);
echo $row2[“name”];
echo “</td>”;
$result3=mysql_query(“select name from teams where team_id=$away”);
$row3 = mysql_fetch_array($result3);
echo “<td width=’8′>”;
echo $row[“hscr”];
echo “</td>”;
echo “<td width=’8′>”;
echo “-“;
echo “</td>”;
echo “<td width=’8′>”;
echo $row[“ascr”];
echo “</td>”;
echo “<td wıdth=’138′ align=’left’ class=’$baran2′>”;
echo $row3[“name”];
echo “</td>”;
echo “</tr>”;
}
echo”</table>”;
}
i will try to demonstrate my result with borders :
[COLOR=”Red”]stars do not exist
and if i run the same function for an other team the result is
Obviously i want my results centered like this
Thank you for your help