-4
我遇到了一個問題,我無法讓我的單元格看起來像一個按鈕。我使用表格作爲導航欄,我希望單元格是一個按鈕。HTML單元格按鈕
對於HTML部分:
<table cellspacing="0" class="maintablewrapper_table01">
<tr class="maintablewrapper_tr01">
<th class="maintablewrapper_tr01_th01" colspan="6">Site Header<br><br>Head</th>
</tr>
<tr class="maintablewrapper_tr02">
<td class="tdlink" onclick="window.location('http://www.google.com');">Home</td>
<td>Producten</td>
<td>Diensten</td>
<td>Over ons</td>
<td>Informatie</td>
<td>Contact</td>
</tr>
</table>
幫助非常感謝
「我用一個表作爲導航欄」。 - 請不要。導航欄(語義上)是用於導航的鏈接的列表。 HTML包含導航,列表和鏈接元素。 – Quentin 2015-02-11 09:25:37
你想讓它看起來像一個按鈕。你需要一些CSS。哪裏是?不過,我同意昆汀的觀點,不要使用'
好的,謝謝,這更多的是一個實驗。 – Floris 2015-02-11 09:29:53
回答
因爲你沒有把你的CSS在這裏,或者你會如何想看到它,我假設最簡單的。
這樣,在最粗糙的層面上,模擬您可能想要做的事情。
CSS:
這... http://jsfiddle.net/550k4gm4/3/
來源
2015-02-11 09:30:24
相關問題