2017-05-24 39 views
0

我有一個表,就像enter image description here 您可以在課程欄下的Operation Research下方看到邊框。我希望刪除邊框,但我寫的代碼不起作用,我該怎麼做?刪除特定td的底部邊框

<html> 
 
    \t <body> 
 
    \t \t <table width="100%" border="1" rules="cols" style="border-collapse : collapse;"> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td align="center" width="54%" style="border : solid thin;">Courses</td> 
 
    \t \t \t \t <td align="center" width="23%" style="border : solid thin;">CGPA</td> 
 
    \t \t \t \t <td align="center" width="23%" style="border : solid thin;">Credit</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>English Language Course</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Additional Language Course<br>&nbsp;French</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Foundation Course</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Core Course<br>Physics<br>&nbsp;Physics</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Complementary Course(s) <br>&nbsp;Mathematics <br>&nbsp;Chemsitry </td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td style="border-bottom : none;">Open Course <br>&nbsp;Operations Research</td> 
 
    \t \t \t \t <td align="center" style="border-bottom : solid thin;">8.1</td> 
 
    \t \t \t \t <td align="center" style="border-bottom : solid thin;">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr height="35px"> 
 
    \t \t \t \t <td></td> 
 
    \t \t \t \t <td align="center" colspan="2">Semester wise SCPA</td> 
 
    \t \t \t </tr> \t \t \t 
 
    \t \t </table> 
 
    \t \t <table width="100%"> 
 
    \t \t \t <tr> 
 
    \t \t \t \t 
 
    \t \t \t </tr> \t \t \t 
 
    \t \t </table> 
 
    \t </body> 
 
    </html>

+0

只是爲了澄清:究竟這個邊界是否要刪除?你正在使用樣式設置和邊框,所以你爲什麼不改變它們? – Deathstorm

回答

1

既然是表的邊界,你必須刪除。

使用下面的代碼

<html> 
 
    \t <body> 
 
    \t \t <table width="100%" border="1" rules="cols" style="border : none;"> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td align="center" width="54%" style="border : solid thin;">Courses</td> 
 
    \t \t \t \t <td align="center" width="23%" style="border : solid thin;">CGPA</td> 
 
    \t \t \t \t <td align="center" width="23%" style="border : solid thin;">Credit</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>English Language Course</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Additional Language Course<br>&nbsp;French</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Foundation Course</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Core Course<br>Physics<br>&nbsp;Physics</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Complementary Course(s) <br>&nbsp;Mathematics <br>&nbsp;Chemsitry </td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td style="border-bottom : none;">Open Course <br>&nbsp;Operations Research</td> 
 
    \t \t \t \t <td align="center" style="border-bottom : solid thin;">8.1</td> 
 
    \t \t \t \t <td align="center" style="border-bottom : solid thin;">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr height="35px"> 
 
    \t \t \t \t <td></td> 
 
    \t \t \t \t <td align="center" colspan="2" style="border : solid thin;">Semester wise SCPA</td> 
 
    \t \t \t </tr> \t \t \t 
 
    \t \t </table> 
 
    \t \t <table width="100%"> 
 
    \t \t \t <tr> 
 
    \t \t \t \t 
 
    \t \t \t </tr> \t \t \t 
 
    \t \t </table> 
 
    \t </body> 
 
    </html>

1

如果你指的main tableborder-bottom然後只將其設置爲下面的border-bottom:none;

<table width="100%" border="1" rules="cols" style="border-collapse : collapse;border-bottom:none"> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td align="center" width="54%" style="border : solid thin;">Courses</td> 
 
    \t \t \t \t <td align="center" width="23%" style="border : solid thin;">CGPA</td> 
 
    \t \t \t \t <td align="center" width="23%" style="border : solid thin;">Credit</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>English Language Course</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Additional Language Course<br>&nbsp;French</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Foundation Course</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Core Course<br>Physics<br>&nbsp;Physics</td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td>Complementary Course(s) <br>&nbsp;Mathematics <br>&nbsp;Chemsitry </td> 
 
    \t \t \t \t <td align="center">8.1</td> 
 
    \t \t \t \t <td align="center">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr> 
 
    \t \t \t \t <td style="border-bottom : none;">Open Course <br>&nbsp;Operations Research</td> 
 
    \t \t \t \t <td align="center" style="border-bottom : solid thin;">8.1</td> 
 
    \t \t \t \t <td align="center" style="border-bottom : solid thin;">19</td> 
 
    \t \t \t </tr> 
 
    \t \t \t <tr height="35px"> 
 
    \t \t \t \t <td></td> 
 
    \t \t \t \t <td align="center" colspan="2" style="border-bottom:solid thin">Semester wise SCPA</td> 
 
    \t \t \t </tr> \t \t \t 
 
    \t \t </table> 
 
    \t \t <table width="100%"> 
 
    \t \t \t <tr> 
 
    \t \t \t \t 
 
    \t \t \t </tr> \t \t \t 
 
    \t \t </table>

+0

@ArunSudhakaran如果你不想刪除完整的邊框,以後再添加,那麼肯定我會添加TD邊框 - 底部:固體薄。 – frnt