0% found this document useful (0 votes)
16 views

HTML Basic

This is basic HTML slide, What is html and how it work.

Uploaded by

Sajjad Khan8254
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

HTML Basic

This is basic HTML slide, What is html and how it work.

Uploaded by

Sajjad Khan8254
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 22

HTML BASIC

Feroza Naznin
Lecturer, GUB
What is HTML?

• HTML stands for Hyper Text Markup Language.


It is a language of World Wide Web. It is a
standard text formatting language which is
used to create and display pages on the Web.
It makes the text more interactive and
dynamic. It can turn text into images, tables,
links.
What are Tags?

• HTML tags are composed of three things: an opening tag, content and
ending tag.
• Some tags are unclosed tags.

 HTML documents contain two things:


• content, and
• tags

When a web browser reads an HTML document, the browser reads it from top
to bottom and left to right. HTML tags are used to create HTML documents and
render their properties. Each HTML tags have different properties.
Syntax
 <tag> content </tag>
Content is placed between tags to display data on the web page.
Do all HTML tags have an end tag?

No.

There are some HTML tags that don't need a closing tag. For
example:
• <image> tag
• <br> tag.

<br> Tag: br stands for break line, it breaks the line of the
code.
<hr> Tag: hr stands for Horizontal Rule. This tag is used to put
a line across the webpage.
What is formatting in HTML?

The HTML formatting is a process of format the text for a better


look and feel. It uses different tags to make text bold, italicized,
underlined.
• Physical tag: These tags are used to provide the visual
appearance to the text.
• Logical tag: These tags are used to add some logical or
semantic value to the text.

<b> This is a physical tag, which is used to bold the text written between it.

<strong> This is a logical tag, which tells the browser that the text is important.
How many types of heading does an
HTML contain?
The HTML contains six types of headings which
are defined with the <h1> to <h6> tags.
Each type of heading tag displays different text
size from another. So
• <h1> is the largest heading tag and
• <h6> is the smallest one.
How to create a hyperlink in HTML?

The HTML provides an anchor tag to create a hyperlink that links


one page to another page. These tags can appear in any of the
following ways:
• Unvisited link - It is displayed, underlined and blue.
• Visited link - It is displayed, underlined and purple.
• Active link - It is displayed, underlined and red.
HTML Anchor
The HTML anchor tag defines a hyperlink that links one page to another page.
It can create hyperlink to other web page as well as files, location, or any URL.
The "href" attribute is the most important attribute of the HTML a tag. and
which links to destination page or URL.
href attribute of HTML anchor tag:

The href attribute is used to define the address of the file to be


linked. In other words, it points out the destination page.

The syntax of HTML anchor tag is given below.

<a href = "..........."> Link Text </a>

Let's see an example of HTML anchor tag.

<a href="second.html">Click for Second Page</a>


What is the difference between HTML elements and
tags?

HTML elements communicate to the browser to render text.


When the elements are enclosed by brackets <>, they form
HTML tags.
Most of the time, tags come in a pair and surround content.

• A text header, denoted using the <h1>, <h2>, <h3>, <h4>,


<h5>, <h6> tags.
• A paragraph, denoted using the <p> tag.
What are some common lists that are used when designing a
page?

There are many common lists which are used to design a page.
You can choose any or a combination of the following list types:

• Ordered list - The ordered list displays elements in numbered


format. It is represented by <ol> tag.
• Unordered list - The unordered list displays elements in
bulleted format. It is represented by <ul> tag.
• Definition list - The definition list displays elements in
definition form like in dictionary.
The <dl>, <dt> and <dd> tags are used to define description list.
HTML List Tags
What is semantic HTML?

Semantic HTML is a coding style. It is the use of HTML markup to


reinforce the semantics or meaning of the content.

For example:
• In semantic HTML <b> </b> tag is not used for bold statement
as well as <i> </i> tag is used for italic.
• Instead of these we use <strong></strong> and <em></em>
tags.
Which HTML tag is used to display the
data in the tabular form?
What is an image map?

Image map facilitates you to link many different


web pages using a single image.

It is represented by <map> tag.

You can define shapes in images that you want


to make part of an image mapping.
How to insert a copyright symbol on a browser
page?

You can insert a copyright symbol by using


 &copy; or &#169; in an HTML file.
Example:
Source code:
<footer>&copy; Copyright 2020 HTML.am</footer>
Result:
© Copyright 2020 HTML.am
How to create a nested webpage in HTML?

The HTML iframe tag is used to display a nested webpage. In other


words, it represents a webpage within a webpage.
The HTML <iframe> tag defines an inline frame.

For example:

<!DOCTYPE html>
<html>
<body>
<h2>HTML Iframes example</h2>
<p>Use the height and width attributes to specify the size of the iframe:</p>
<iframe src="https://www.javatpoint.com/" height="300" width="400"></iframe>
</body>
</html>
How do you keep list elements straight in an HTML file?

You can keep the list elements straight by using


indents.
HTML Block <div> Elements

• The <div> tag defines a division or a section in


an HTML document.
• The <div> tag is used as a container for HTML
elements
• which is then styled with CSS or manipulated
with JavaScript.
• The <div> tag is easily styled by using the class
or id attribute.
Block-level Elements
HTML Inline <span> Elements
Definition :
The <span> tag is an inline container used to
mark up a part of a text, or a part of a
document.
Usage:
Browser Support Element ·
Global Attributes.
More Inline Elements

You might also like