New
button.File
> Save As
.<h1>
, <p>
, <a>
.<tag>
. Most tags come in pairs: one for opening and one for closing, e.g., <h1>Hello</h1>
.href
for links or src
for images, e.g., <a href="https://example.com">
.<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>Hello, World!</h1>
<p>This is an HTML document.</p>
</body>
</html>
This example shows the structure of a basic HTML page. The <html>
tag encloses the whole document. The <head>
section contains metadata (like the title of the page), and the <body>
section contains the actual content that is visible to the user.<!DOCTYPE html>
).
<header>
, <footer>
, and <nav>
elements are used to structure the page. Here’s what they do:
<ol>
) and unordered lists (<ul>
) to define each individual item in the list.<header>
<h1>My Website</h1>
<nav>
<ul>
<li><a href="#home">Home</a></li>
<li><a href="#about">About</a></li>
<li><a href="#contact">Contact</a></li>
</ul>
</nav>
</header>
<footer>
<p>© 2025 My Website. All rights reserved.</p>
</footer>
This example demonstrates how to create a header with a navigation bar and a footer with copyright text. The list in the navigation section is an unordered list (<ul>
) with links to different sections of the website.
action
and method
attributes to specify where the data goes and how it's sent (usually through GET or POST methods).<form action="/submit" method="POST">
<label for="name">Name:</label>
<input type="text" id="name" name="name">
<button type="submit">Submit</button>
</form>
In this example, the form will send data to "/submit" when the submit button is pressed, using the POST method.
<img>
tag is used to display images in an HTML page. The src
attribute specifies the image source, and the alt
attribute provides alternative text for the image if it cannot be displayed.<img src="image.jpg" alt="Description of the image">
Common attributes for <img>
include:
<video>
tag. You can also use the controls
attribute to allow users to play, pause, and control the volume of the video.<video width="320" height="240" controls>
<source src="movie.mp4" type="video/mp4">
<source src="movie.ogg" type="video/ogg">
Your browser does not support the video tag.
</video>
<audio>
tag is used to embed sound files, such as MP3 or WAV. The controls
attribute enables the user to control playback.<audio controls>
<source src="audio.mp3" type="audio/mp3">
Your browser does not support the audio element.
</audio>
autoplay
attribute allows the media to start playing as soon as it's loaded.loop
attribute causes the media to automatically restart when it finishes.muted
attribute prevents the media from making sound.<div>
tag is a block-level element used to group content. It does not have any visual effect but can be used for styling or structuring content.<div>Content goes here</div>
<p>
tag defines a paragraph of text. It automatically adds space before and after the text for readability.<p>This is a paragraph</p>
<a>
tag defines a hyperlink. The href
attribute specifies the URL the link points to.<a href="https://www.example.com">Click Here</a>
<img>
tag is used to display images. The src
attribute specifies the image source and alt
is used for alternative text if the image cannot be displayed.<img src="image.jpg" alt="Description">
<h1>
is the largest, typically used for the main heading, while <h2>
and other heading tags define subheadings.<h1>This is a main heading</h1>
<ul>
is for unordered lists, <ol>
is for ordered lists, and <li>
defines each list item.<ul>
<li>Item 1</li>
<li>Item 2</li>
</ul>
<form>
tag is used to create interactive forms for gathering user input. Common form elements include <input>
, <select>
, and <button>
.<form>
<input type="text" name="username">
<input type="submit">
</form>
<span>
tag is an inline element used for grouping small parts of text or other inline elements.<span style="color: red">Red Text</span>
<header>
, <footer>
, and <article>
helps make your code more readable and accessible.class
, id
, and style
to customize the behavior and appearance of elements.href
, src
, and others.id
, class
, and element selectors.🎯 Goal: Build a strong CSS foundation for designing clean and attractive webpages.
display
, position
, and float
.🎯 Goal: Build on the basics and start designing structured, modern layouts with CSS.
🎯 Goal: By the end of this course, you'll be able to use POE AI effectively to enhance your workflows.