Home>Article>Web Front-end> How to remove html table border

How to remove html table border

藏色散人
藏色散人 Original
2021-04-12 09:06:41 17594browse

Method to remove html table border: first create an HTML sample file; then create the table content through the table tag in the body; finally pass css attributes such as "border-left: none;border-right: none;" Just remove the specified table border.

How to remove html table border

The operating environment of this article: Windows7 system, CSS3&&HTML5 version, Dell G3 computer.

Table in HTML removes the left and right borders

.table { text-align: center; } .table table { font-size: 14px; border-collapse: collapse; width: 70%; table-layout: fixed; text-align: center; line-height: 25px; margin:0 auto; } .table table tr { border: dashed 1px #a59e9e; border-left: none; border-right: none; }

The effect is as shown in the figure:

Attached is the original html code:

   Table去掉左右两边的边框 

人员信息

姓名 性别 年龄 出生日期 地址
小明 20 1998-10-12 北京市
小花 19 1999-02-02 上海市
小强 22 1996-05-04 上海市

[Recommended learning:css video tutorial]

The above is the detailed content of How to remove html table border. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn