HTML table tag tutorial (31): cell width and height attributes WIDTH, HEIGHT

HTML table tag tutorial (31): cell width and height attributes WIDTH, HEIGHT

By default, the width and height of the cell are automatically adjusted according to the content, and we can also manually set the width and height of the cell.
Basic syntax
<TD WIDTH=value HEIGHT=value>
Syntax explanation <br />The WIDTH attribute defines the width of the cell, and the HEIGHT attribute defines the height of the cell, in pixels or percentage.
File example: 10-29.htm
Set the width and height of the cell.
01 <!-- ------------------------------ -->
02 <!-- File example: 10-29.htm -->
03 <!--File Description: Set the width and height of the cell-->
04 <!-- ------------------------------ -->
05 <HTML>
06 <HEAD>
07 <TITLE>Setting the width and height of the cell</TITLE>
08 </HEAD>
09 <BODY>
10 <H1>Mainstream web design software</H1>
11 <TABLE BORDER=1 WIDTH=400 HEIGHT=100>
12 <TR>
13 <TD WIDTH=300 height=50>Web Graphics Software</TD><TD>Fireworks</TD>
14 </TR>
15 <TR>
16 <TD>Web page creation software</TD><TD>Dreamweaver</TD>
17 </TR>
18 <TR>
19 <TD>Web animation software</TD><TD>Flash</TD>
20 </TR>
21 </TABLE>
22 </BODY>
23 </HTML>
File Description <br />Line 11 defines the table's width as 400 pixels and its height as 100 pixels. Line 13 defines the cell width as 300 pixels and height as 50 pixels.

<<:  Using zabbix to monitor the ogg process (Linux platform)

>>:  Native JS to implement sharing sidebar

Recommend

In-depth analysis of MySQL query interception

Table of contents 1. Query Optimization 1. MySQL ...

Docker installation and configuration image acceleration implementation

Table of contents Docker version Install Docker E...

How to encapsulate the carousel component in Vue3

Purpose Encapsulate the carousel component and us...

Docker FAQ

Docker only maps ports to IPv6 but not to IPv4 St...

How to separate static and dynamic state by combining Apache with Tomcat

Experimental environment Apache and Tomcat are bo...

Install Percona Server+MySQL on CentOS 7

1. Environmental Description (1) CentOS-7-x86_64,...

MySQL character types are case sensitive

By default, MySQL character types are not case-se...

Share some tips on using JavaScript operators

Table of contents 1. Optional chaining operator [...

Vue realizes adding watermark to uploaded pictures (upgraded version)

The vue project implements an upgraded version of...

MySql multi-condition query statement with OR keyword

The previous article introduced the MySql multi-c...

JavaScript recursion detailed

Table of contents 1. What is recursion? 2. Solve ...

Detailed explanation of HTML onfocus gain focus and onblur lose focus events

HTML onfocus Event Attributes Definition and Usag...

Analysis of SQL integrity constraint statements in database

Integrity constraints Integrity constraints are f...