0% found this document useful (0 votes)
7 views4 pages

HTML Notes

The document provides a comprehensive overview of HTML coding, including structure, tags, and attributes. It covers essential elements such as linking CSS, creating hyperlinks, embedding images, audio, and video, as well as using meta tags for metadata. Additionally, it explains how to format tables and set dimensions for cells and media elements.

Uploaded by

sanskrutihb
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views4 pages

HTML Notes

The document provides a comprehensive overview of HTML coding, including structure, tags, and attributes. It covers essential elements such as linking CSS, creating hyperlinks, embedding images, audio, and video, as well as using meta tags for metadata. Additionally, it explains how to format tables and set dimensions for cells and media elements.

Uploaded by

sanskrutihb
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

HTML Codes

<!Doctype html> comment line “!”

<!Name, Center Number, Candidate Number>

………………………………………………………………………………………………………
……………….

<html>

<head>

<title>My Page</title>

</head>

<body>

</body>

</html>

………………………………………………………………………………………………………
……………………………………

Html files need to saved with “ .html” extension.

………………………………………………………………………………………………………
……………………………….

<…></…> paired tag

<…> unpaired tag

<br>

<hr>

………………………………………………………………………………………………………
…………………………………

1. To join the css page:


<link rel="stylesheet" type="text/css" href="name_of_the_file.css">
2. To create id on page for creating hyperlink on a same page:

<a id="top"></a>

………

<a href="#top">Return to the top</a>

………………………………………………………………………………………………………
………………………………..

3. For align the table center:

<table style="margin-left:auto; margin-right:auto;">

<table style="margin-left:10%; margin-right:20%;">

………………………………………………………………………………………………………
…………………………………

4. For merging the row:

<td rowspan="n">

5. For merging the column:

<td colspan="n">

………………………………………………………………………………………………………
……………………………….

6. For inserting image:

<img src="name_of_the_image.jpg" alt="Text need to write" style="width:dimension;


height:dimension">

………………………………………………………………………………………………………
………………………………..

7. For setting up the dimension of cell:

<td style="width:dimension; height:dimension">… </td>

8. For hyperlink: 350*200

<a href=”name of the link with extention”>…. </a>

9. For sending mail:


<a href="[Link] me a website!">Hothouse
Design</a>

Set the hyperlink in a new tab

<a href="[Link] target="_new">

Set the hyperlink in the same tab

<a href="[Link] target="_self">

<audio controls>
<source src="[Link]" type="audio/ogg">
<source src="horse.mp3" type="audio/mpeg">
Your browser does not support the audio tag.
</audio>

There are three supported audio formats in HTML: MP3, WAV, and OGG.

<video width="320" height="240" controls>


<source src="movie.mp4" type="video/mp4">
<source src="[Link]" type="video/ogg">
Your browser does not support the video tag.
</video>

There are three supported video formats in HTML: MP4, WebM, and OGG

<img src="[Link]">

<head>
<meta charset="UTF-8">
<meta name="description" content="Free Web tutorials">
<meta name="keywords" content="HTML, CSS, JavaScript">
<meta name="author" content="John Doe">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>

The <meta> tag defines metadata about an HTML document. Metadata is data (information)
about data.

<meta> tags always go inside the <head> element, and are typically used to specify character set,
page description, keywords, author of the document, and viewport settings.

Metadata will not be displayed on the page, but is machine parsable.


Metadata is used by browsers (how to display content or reload page), search engines
(keywords), and other web services.

There is a method to let web designers take control over the viewport (the user's visible area of a
web page), through the <meta> tag (See "Setting The Viewport" example below).

Attribute Value Description

charset character_set Specifies the character encoding for the HTML document

content text Specifies the value associated with the http-equiv or name
attribute

http-equiv content- Provides an HTTP header for the information/value of the


security-policy content attribute
content-type
default-style
refresh

name application- Specifies a name for the metadata


name
author
description
generator
keywords
viewport

You might also like