0
我遇到了CSS問題。當我在Apple Safari中查看我的頁面時,頁面的樣式是正確的。但是,當我在Google Chrome或Mozilla Firefox中查看我的頁面時,頁面的樣式不正確。首先,a,table,th和td標籤在Firefox和Google Chrome中不起作用。其他一切似乎都運作良好。CSS樣式表:A,TD,TH和表標籤
這裏是我的樣式表:
a{
margin-left:300px;
font-family:Arial, Helvetica, sans-serif;
}
br{
clear: left;
}
font{
font-family:Arial, Helvetica, sans-serif;
}
label{
font-family:Arial, Helvetica, sans-serif;
float: left;
display: block;
width: 300px;
}
legend{
color:#ff0000;
font-family:Arial, Helvetica, sans-serif;
font-weight: bold;
}
table{
margin-left:300px;
}
td{
font-family:Arial, Helvetica, sans-serif;
}
textarea{
width: 300px;
height: 150px;
}
th{
color:#ff0000;
font-family:Arial, Helvetica, sans-serif;
}
.width{
width: 300px;
}
這裏是我的整個HTML頁面。
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>ACISS | Statute Search</title>
<link rel="stylesheet" type="text/css" href="statute.css" />
</head>
<body>
<font>
Your search yielded the following results:
</font>
<table border='1'>
<tr>
<th>ACISS Statute</th>
<th>ACISS Charge</th>
<th>UCR</th>
</tr>
<?php
while($row = mysql_fetch_array($result)){?>
<tr>
<td><?php echo $row['ACISS_statute']?></td>
<td><?php echo $row['ACISS_charge_name']?></td>
<td><?php echo $row['ACISS_UCR']?></td>
</tr>
<?php } ?>
</table>
<br />
<a href="http://localhost:80/statute_search/">Click Here to Search Again</a>
</body>
</html>
HTML也會有幫助。 –
鏈接會更好。 – ninetwozero
'font-family'並不需要聲明太多...... –