这似乎是一个愚蠢的问题,我知道如何在正常的html过程中删除下划线,但在使用php时似乎无法解决。
这是我的代码
while($row = mysql_fetch_array($oteaminfo))
{
echo "<tr>";
echo '<td><a href="cnghlplayerinfo.php?PlayerID='.$row['PlayerID'].' style="text-decoration:none;">'.$row['FullName'].'</a></td>';
echo "<td>".$row['Position']."</td> ";
echo "<td>".$row['Height']."</td> ";
echo "<td>".$row['Weight']."</td> ";
echo "<td>".$row['DOB']."</td> ";
echo "<td>".$row['Team']."</td> ";
echo "<td>".$row['CNGHLRights']."</td> ";
echo "<td>".$row['InternationalTeam']."</td> ";
echo "<td>".$row['InternationLeague']."</td> ";
echo "</tr>";
}
echo "</table>";
我四处搜索,但找不到任何关于php下划线删除的信息,所以我想我会问这个问题。
谢谢你的帮助。
href
值之后缺少"
更换此
echo '<td><a href="cnghlplayerinfo.php?PlayerID=' . $row['PlayerID'] . ' style="text-`decoration:none;">' . $row['FullName'] . '</a></td>';`
以下
echo '<td><a href="cnghlplayerinfo.php?PlayerID=' . $row['PlayerID'] . '" style="text-decoration:none;">' . $row['FullName'] . '</a></td>';
我建议不要使用inline css
,而是使用css class
<style>
a,a:hover
{
text-decoration:none;
}
</style>