我的网站上有这张表,我想将其切换为使用 div,但我仍在研究 HTML,不知道如何去做。我有一个名为 theme.css 的 CSS,我知道其中有一些东西可以使它起作用。
<table>
<tr>
<td>
<table>
<tr>
<td class="cellWidth">
<img src="4-cute-cats.jpg" class="centerImage" width="300" height="300" />
<p class="centerText">They hunt in packs.</p>
</td>
<td>
<img src="cat_sniping.jpg" class="centerImage" width="256" height="192" />
<p class="centerText">Sniper Cat</p></a>
</td>
<td class="cellWidth">
<img src="LOL1.jpg" class="centerImage" width="300" height="298" />
<p class="centerText">Sneaking Cat</p>
</td>
<td class="cellWidth">
<img src="hammercat.jpg" class="centerImage" width="300" height="163" />
<p class="centerText">80s Cat</p>
</td>
</tr>
<tr>
<td class="cellWidth">
<img src="kittytrap.jpg" class="centerImage" width="200" height=492 />
<p class="centerText">It's a trap!</p>
</td>
<td class="cellWidth">
<img src="chop-cats.jpg" class="centerImage" width="300" height="140" />
<p class="centerText">They can strip a car to the frame in under 2:00 minutes.</p>
</td>
<td class="cellWidth">
<img src="smartkat.jpg" class="centerImage" width="200" height="338" />
<p class="centerText">Intelligent cat.</p></a>
</td>
<td class="cellWidth">
<img src="narniacat.jpg" class="centerImage" width="200" height="337" />
<p class="centerText">Once a cat of Narnia always a cat of Narnia.</p>
</td>
</tr>
<tr>
<td class="cellWidth">
<img src="lolcats3.jpg" class="centerImage" width="300" height="108" />
<p class="centerText">Tired cat.</p>
</td>
<td class="cellWidth">
<img src="lol_cats_1.jpg" class="centerImage" width="300" height="142" />
<p class="centerText">Gollum Cat.</p>
</td>
<td class="cellWidth">
<img src="Magical-Kitty.png" class="centerImage" width="300" height="180" />
<p class="centerText">Super Cat.</p>
</td>
<td class="cellWidth">
<img src="sad-kitty.jpg" class="centerImage" width="300" height="188" />
<p class="centerText">Sad Kitty.</p>
</td>
</tr>
<tr>
<td class="cellWidth">
<img src="cat-in-your-wallpaper.jpg" class="centerImage" width="300" height="200" />
<p class="centerText">Wallpaper cat.
</td>
<td class="cellWidth">
<img src="thinking-cat.jpg" class="centerImage" width="300" height="475" />
<p class="centerText">Thinking cat.</p>
</td>
<td class="cellWidth">
<img src="http://3.bp.blogspot.com/_znuneBeHigk/TSOOr5DuoQI/AAAAAAAABFY/-Rpe8S1uRo8/s1600/000.jpg&w=823&h=618&ei=_A4VUfP7L4Gy2QXJ-oHIDQ&zoom=1&ved=1t:3588,r:79,s:0,i:354&iact=rc&dur=2621&sig=108293906633680688065&page=3&tbnh=172&tbnw=231&start=67&ndsp=38&tx=64&ty=72" class="centerImage" width="300" height="225" />
<p class="centerText">Gamer Kitty.</p>
</td>
<td class="cellWidth">
<img src="http://www.dumpaday.com/wp-content/uploads/2013/01/funny-lol-cats-playing-with-toilet-paper1.jpg" class="centerImage" width="300" height="504" />
<p class="centerText">Couch cat.</p>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="center">
<a href="morekitties.html">More Kitties</a>
</td>
</tr>
</table>