1.文字繞圖
如果我們使用正常的,例如:
<TABLE cellpadding="15" width="200">
<TR>
<TD bgcolor="#EEEEFF"><IMG src="test.gif" hight=60>這里是普通的。國(guó)內(nèi)的VB網(wǎng)站中vbgood以每日更新,資料量豐富,而深受程序愛(ài)好者的喜歡。</TD>
</TR>
</TABLE>
這樣的語(yǔ)句中圖片比文字高度要高,則文字上部會(huì)有空白出現(xiàn)。頁(yè)面的效果非常不好。如何解決呢?請(qǐng)看這個(gè)代碼:
<TABLE cellpadding="15" width="200">
<TR>
<TD bgcolor="#EEEEFF"><IMG src="test.gif" hspace="1" align="LEFT" hight=60>這里是繞排的。國(guó)內(nèi)的VB網(wǎng)站中vbgood以每日更新,資料量豐富,而深受程序愛(ài)好者的喜歡。</TD>
</TR>
</TABLE>
在img這個(gè)元素中加入這個(gè)屬性就可以解決:align="center",問(wèn)題就可以解決了。簡(jiǎn)單吧!至于hspace是定義圖片與周圍元素的寬度。于是否繞排無(wú)關(guān)系。
這有是怎么作出來(lái)的呢?先看看這個(gè)代碼:
<table align=left cellspacing=0 cellpadding=0 width=200 border=1>
<tr>
<td><table align=left cellspacing=0 cellpadding=0><font color=red size="5"><b>在</b></font> </table>國(guó)內(nèi)的VB網(wǎng)站中vbgood以每日更新,資料量豐富,而深受程序愛(ài)好者的喜歡。(End)</td></tr>
</table>
這樣的效果又怎么實(shí)現(xiàn)呢?
<table align=left cellspacing=0 cellpadding=0 width=200 border=1>
<tr>
<td><table align=left cellspacing=0 cellpadding=0><font color=red size="5"><b>在</b></font>
</table>國(guó)內(nèi)的VB網(wǎng)站中vbgood以每日更新,資料量豐富,而深受程序愛(ài)好者的喜歡。(End)</td></tr>
</table>
這段代碼就說(shuō)明了,聰明的你一看就知道了,只要把要放大的字放在這個(gè)table中就可以了。
但現(xiàn)在如果我要讓文字有背景色,有怎么辦呢?哈,你真聰明,在table中加bgcolor屬性,這樣:
<table align=left cellspacing=0 cellpadding=0 width=200 border=1>
<tr>
<td><table align=left cellspacing=0 cellpadding=0 bgcolor=#C0C0C0><font color=red size="5"><b>在</b></font></table>國(guó)內(nèi)的VB網(wǎng)站中vbgood以每日更新,資料量豐富,而深受程序愛(ài)好者的喜歡。(End)</td></tr></table>
但能出來(lái)嗎?是不能,還要加?xùn)|西呢(記得下次不要這么快回答哦:),這樣:
<table align=left cellspacing=0 cellpadding=0 width=200 border=1>
<tr>
<td><table align=left cellspacing=0 cellpadding=0 bgcolor=#C0C0C0><td><font color=red size="5"><b>在</b></font></td></table>國(guó)內(nèi)的VB網(wǎng)站中vbgood以每日更新,資料量豐富,而深受程序愛(ài)好者的喜歡。(End)</td></tr></table>