2014-03-27 36 views
-1

缺少邊界,我有以下的代碼爲一個HTML表格

<html> 
<head> 
<body bgcolor="#BDBDBD"> 
<div align="center"> 
<font color="Blue"> 
<CAPTION><b><u><i>SYSTEM STATUS</i></u></b></caption> 
</font> 
</br> 
</br> 

<table BORDER="2" BORDERCOLOR="Black" CELLPADDING="3"> 

<colgroup> 
<col span="2" style="background-color:FFA04A"> 
<col style="background-color:FFA04A"> 
</colgroup> 

<thead> 
<tr> 
<font color="Blue"> 
     <th><font color="Blue">System</font></th> 
     <th><font color="Blue">Is Alive</font></th> 
     </font> 
</tr> 
</thead> 
</font> 
</body> 
</head> 
</html> 

我得到的輸出與黑色邊框但方式隔開列missing..is什麼錯誤代碼的邊界爲atable。

Fiddle

+0

糾正你的HTML之後,它工作正常這裏http://jsfiddle.net/Vinay199129/8E75t/ – Rex

+4

也許你應該看看了如何HTML這些日子已經完成了。這在現代網絡上已經過時了。使用CSS。 – Luaan

+0

這段代碼看起來像是從'90開始的。如果您正在學習HTML和CSS,那麼請將您的源代碼改爲現代。 – Volvox

回答

0

我認爲你是初學者,請參閱該代碼

<html> 
    <head></head> 
    <body bgcolor="#BDBDBD"> 
    <div align="center"> 
    <font color="Blue"> <b><u><i>SYSTEM STATUS</i></u></b> </font> </br> 
    </br> 
    <table BORDER="2" BORDERCOLOR="Black" CELLPADDING="3"> 
    <colgroup> 
    <col span="2" style="background-color:FFA04A"> 
    <col style="background-color:FFA04A"> 
    </colgroup> 
    <thead> 
     <tr> <font color="Blue"> 
     <th><font color="Blue">System</font></th> 
     <th><font color="Blue">Is Alive</font></th> 
     </font> </tr> 
    </thead> 
    </font> 
    </body> 
    </html> 

演示:http://jsfiddle.net/26TCe/

0

description of: 「標籤指定一個元素中的每一列列的屬性。」 你必須定義3個要素:插入一個(空)<th/>

之間