Curriculum
Course: HTML Basic
Login

Curriculum

HTML Basic

HTML Introduction

0/1

HTML Editors

0/1

HTML Elements

0/1

HTML Attributes

0/1

HTML Headings

0/1

HTML Paragraphs

0/1

HTML Styles

0/1

HTML Formatting

0/1

HTML Quotation

0/1

HTML Comments

0/1

HTML Colors

0/1

HTML Favicon

0/1

HTML Page Title

0/1

HTML Block and Inline

0/1

HTML Iframes

0/1

HTML Java Script

0/1

HTML File Paths

0/1

HTML - The Head Element

0/1

HTML Style Guide

0/1

HTML Entities

0/1

HTML Symbols

0/1
Text lesson

Colspan & Rowspan

HTML tables can include cells that extend across multiple rows and/or columns.

IMG_3839

HTML Table – Colspan

To have a cell cover multiple columns, utilize the colspan attribute.

 Example

<table>
  <tr>
    <th colspan=”2″>Name</th>
    <th>Age</th>
  </tr>
  <tr>
    <td>Jill</td>
    <td>Smith</td>
    <td>43</td>
  </tr>
  <tr>
    <td>Eve</td>
    <td>Jackson</td>
    <td>57</td>
  </tr>
</table>
Certainly! The number indicated by the “colspan” attribute signifies the amount of columns to extend across.

HTML Table – Rowspan

To have a cell cover multiple rows, employ the “rowspan” attribute.

 Example

<table>
  <tr>
    <th>Name</th>
    <td>Jill</td>
  </tr>
  <tr>
    <th rowspan=”2″>Phone</th>
    <td>555-1234</td>
  </tr>
  <tr>
    <td>555-8745</td>
</tr>
</table>
Keep in mind: The “rowspan” attribute’s value denotes the quantity of rows to encompass. 

 

Click to Learn