HTML Basics

HTML Introduction HTML Basic HTML Comments HTML Tags/Elements HTML Attributes HTML Formatting HTML Block and Inline HTML Charsets HTML Classes HTML Colors HTML Div HTML Headings HTML Id HTML Iframes HTML Images HTML File Paths HTML Tables HTML Layout HTML Lists HTML Links <a> HTML Paragraphs HTML Quotations HTML JavaScript HTML Emojis HTML URL Encode HTML Entities HTML Computercode HTML Symbols HTML Styles

HTML Forms

HTML Forms HTML Form Elements HTML Form Attributes HTML Input Attributes HTML Input Regex HTML Input Form Attributes HTML Input Types

HTML SEO

HTML Head HTML Page Title HTML Responsive HTML Semantics HTML Favicon

HTML Graphics

HTML Canvas HTML SVG

HTML Media

HTML Media HTML Audio HTML Video

HTML Reference

a abbr acronym address applet area article aside audio b base basefont bdi bdo big blockquote body br button canvas caption center cite code col colgroup data datalist dd del details dfn dialog dir div dl DOCTYPE dt em embed fieldset figcaption figure font footer form frame frameset h1_-_h6 head header hgroup hr html i iframe img input ins kbd label legend li link main map mark menu meta meter nav noframes noscript object ol optgroup option output p param picture pre progress q rp rt ruby s samp script search section select small source span strike strong style sub summary sup svg table tbody td template textarea tfoot th thead time title tr track tt u ul var video wbr

HTML CSS

HTML CSS Tutorial

In this tutorial, we will learn how HTML CSS works together to create stylish and visually appealing web pages. CSS stands for Cascading Style Sheets, and it is used to control the layout and design of a web page.

Step 1: Connecting CSS to HTML

To connect CSS to HTML, we use the <link> tag in the <head> section of the HTML document. The <link> tag has three important attributes: rel, type, and href.

<link rel="stylesheet" type="text/css" href="styles.css">

Step 2: Applying CSS to HTML Elements

To apply CSS styles to HTML elements, we use selectors and declarations. Selectors target specific HTML elements, and declarations define the style properties.

For example, to change the color of all <h1> elements to blue, we would use the following CSS code:

h1 {
  color: blue;
}

Step 3: Adding Styling to Text

We can add styling to text using CSS properties such as font-size, font-family, and text-align. For example, to change the font size of all paragraphs to 16px, we would use the following CSS code:

p {
  font-size: 16px;
}

Fictional Data Example

Name Age Location
John Doe 25 New York
Jane Smith 30 Los Angeles

In this example, we have a fictional table showing the names, ages, and locations of two individuals. We can style this table using CSS to make it more visually appealing.

By following these steps and practicing with different CSS properties, you can create beautiful and responsive web pages using HTML CSS.