SlideShare a Scribd company logo
Chapter 3
Web development
Structure of a website
• website is mostly made up of numerous
webpages. These webpages are HTML
documents that are stored in a directory on
a domain. The domain should not be
confused with the website. The domain is
the internet address via which the content
of the website can be called up.
• HTML is not a programming language but
a page description language:
• In the code, it is defined which element is to
be displayed at which point. This means in
the design of a website, there is not a picture
used for the entire site, rather it is defined in
the code how the font, the colors and, of
course, possible pictures or videos are to be
arranged – depending on what device is
being used (e.g. desktop computer or
smartphone) to access it.
HTML
• HTML stands for HyperText Markup Language.
• HTML is used to create web pages and web
applications.
• HTML is widely used language on the web.
• We can create a static website by HTML only.
HTML text Editors
• An HTML file is a text file, so to create an HTML
file we can use any text editors.
• Text editors are the programs which allow
editing in a written text, hence to create a web
page we need to write our code in some text
editor(Notepad++, Sublime Text, Vim,
etc. )
Building blocks of HTML
• An HTML document consist of its basic building
blocks which are
• Tags: An HTML tag surrounds the content and
apply meaning to it. It is written between < and
> brackets.
• Attribute: An attribute in HTML provides extra
information about the element, and it is applied
within the start tag. An HTML attribute contains
two fields: name & value
Syntax
• <tag name attribute_name= " attr_value"> con
tent </ tag name>
• Elements: An HTML element is an individual
component of an HTML file. In an HTML file,
everything written within tags are termed as
HTML
elements(heading,paragraph,list,table,link and
so on).
All HTML tags must enclosed within < >
these brackets.
Every tag in HTML perform different
tasks.
If you have used an open tag <tag>, then
you must use a close tag </tag> (except
some tags)
Syntax
• <tag> content </tag>
web page.pptxb dvcdhgdhdbdvdhudvehsusvsudb
• Void element: All the elements in HTML do
not require to have start tag and end tag, some
elements does not have content and end tag such
elements are known as Void elements or empty
elements. These elements are also called as
unpaired tag.
• Some Void elements are <br> (represents
a line break) , <hr>(represents a
horizontal line), etc.
• <!DOCTYPE>
• <html>
• <head>
• <title>Web page title</title>
• </head>
• <body>
• <h1>Write Your First Heading</h1>
• <p>Write Your First Paragraph.</p>
• </body>
• </html>
• <html>
• <head>
• <title>The basic building blocks of HTML</title>
• </head>
• <body>
• <h2>The building blocks</h2>
• <p>This is a paragraph tag</p>
• <p style="color: red">The style is attribute of paragrap
h tag</p>
• <span>The element contains tag, attribute and content
</span>
• </body>
• </html>
HTML Attribute
• HTML attributes are special words which provide additional
information about the elements or attributes are the modifier of the
HTML element.
• Each element or tag can have attributes, which defines the behavior
of that element.
• Attributes should always be applied with start tag.
• The Attribute should always be applied with its name and value
pair.
• The Attributes name and values are case sensitive, and it is
recommended by W3C that it should be written in Lowercase only.
Syntax
• <element =attribute name:value">content</element>
• <p style=“color:red”>the first paragraph of the
document</p>
Example of attri.
• <html>
• <head>
• </head>
• <body>
• <h1> This is Style attribute</h1>
• <p style="height: 50px; color: blue">It will add style pr
operty in element</p>
• <p style="color: red">It will change the color of content
</p>
• </body>
• </html>
Example:
• <html>
• <head>
• </head>
• <body>
• <div style="background-color: lightblue">This is first d
div>
• <div style="background-
color: lightgreen">This is second div</div>
• <p style="background-
color: pink">This is a block level element</p>
• </body>
• </html>
HTML Formatting
• is a process of formatting text for better look and
feel. HTML provides us ability to format text
without using CSS. There are many formatting tags
in HTML. These tags are used to make text bold,
italicized, or underlined.
• In HTML the formatting tags are divided into two
categories:
• 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
HTML Heading
• A HTML heading or HTML h tag can be
defined as a title or a subtitle which you
want to display on the webpage. When you
place the text within the heading tags
<h1>.........</h1>, it is displayed on the
browser in the bold format and size of the
text depends on the number of heading.
• There are six different HTML headings
which are defined with the <h1> to <h6>
tags, from highest level h1 (main heading)
to the least level h6 (least important
heading).
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.
• href attribute of HTML & it points out the destination
page.
• The syntax of HTML anchor tag is given below.
• <a href = "..........."> Link Text </a>
• <html>
• <head>
• <title></title>
• </head>
• <body>
• <a href="https://
www.youtube.com/" target="_blank"> this-link </a>
• <a href=“C:UsersHpDesktophi.html>click
here</a>
• </body>
• </html>
Appearance of HTML anchor tag
• An unvisited link is displayed underlined and blue.
• A visited link displayed underlined and purple.
• An active link is underlined and red.
HTML Image
• HTML img tag is used to display image on the web
page. HTML img tag is an empty tag that contains
attributes only, closing tags are not used in HTML
image element.
• <img src="good_morning.jpg" alt="Good Morning Fri
ends"/>
Attributes of HTML img tag
• 1) src(source)
• 2) alt(alternative)
• 3) width
• 4) height
Example:
• <img src="animal.jpg" height="180" width="300
" alt="animal image">
How to get image from another directory/folder?
• <img src="E:/images/
animal.png" height="180" width="300" alt="animal image"
>
Use <img> tag as a link
• We can also link an image with other page or we can use an
image as a link. To do this, put <img> tag inside the <a> tag.
• Example:
• <a href="https://www.javatpoint.com/what-is-
robotics"><img src="robot.jpg" height="100" width="100"
></a>
HTML Table
• HTML table tag is used to display data in tabular form
(row * column). There can be many columns in a row.
• We can create a table to display data in tabular form, using
<table> element, with the help of <tr> , <td>, and <th>
elements.
• In Each table, table row is defined by <tr> tag, table header
is defined by <th>, and table data is defined by <td> tags.
• HTML tables are used to manage the layout of the page e.g.
header section, navigation bar, body content, footer section
etc. But it is recommended to use div tag over table to
manage the layout of the page .
Tag Description
<table> It defines a table.
<tr> It defines a row in a table.
<th> It defines a header cell in a table.
<td> It defines a cell in a table.
<caption> It defines the table caption.
<colgroup> It specifies a group of one or more
columns in a table for formatting.
<col> It is used with <colgroup> element to
specify column properties for each
column.
<tbody> It is used to group the body content
in a table.
<thead> It is used to group the header
content in a table.
<tfooter> It is used to group the footer content
Example
• <table>
• <tr><th>First_Name</th><th>Last_Name</
th><th>Marks</th></tr>
• <tr><td>Sonoo</td><td>Jaiswal</td><td>60</td></
tr>
• <tr><td>James</td><td>William</td><td>80</
td></tr>
• <tr><td>Swati</td><td>Sironi</td><td>82</td></
tr>
• <tr><td>Chetna</td><td>Singh</td><td>72</td></
tr>
• </table>
• 1) HTML Border attribute
• You can use border attribute of table tag in HTML
to specify border. But it is not recommended now.
• <table border="1">
• <tr><th>First_Name</
th><th>Last_Name</th><th>Marks</th></
tr>
• <tr><td>Sonoo</td><td>Jaiswal</
td><td>60</td></tr>
• </table>
HTML Lists
• Ordered List or Numbered List (ol)
• Unordered List or Bulleted List (ul)
• Description List or Definition List (dl
1. Ordered List or Numbered List (ol)
• <ol>
• <li>Aries</li>
• <li>Bingo</li>
• <li>Leo</li>
• <li>Oracle</li>
• </ol>
2. Unordered List or Bulleted List (ul)
• <ul>
• <li>Aries</li>
• <li>Bingo</li>
• <li>Leo</li>
• <li>Oracle</li>
• </ul>
3. Description List or Definition List (dl)
• HTML Description List or Definition List displays
elements in definition form like in dictionary. The
<dl>, <dt> and <dd> tags are used to define
description list.
• The 3 HTML description list tags are given below:
• <dl> tag defines the description list.
• <dt> tag defines data term.
• <dd> tag defines data definition (description).
• </dl>
HTML Form
• An HTML form is a section of a
document which contains controls such as text
fields, password fields, checkboxes, radio
buttons, submit button, menus etc.
• An HTML form facilitates the user to enter data
that is to be sent to the server for processing
such as name, email address, password, phone
number, etc.
Tag Description
<form> It defines an HTML form to enter inputs
by the used side.
<input> It defines an input control.
<textarea> It defines a multi-line input control.
<label> It defines a label for an input element.
<fieldset> It groups the related element in a form.
<select> It defines a drop-down list.
<optgroup> It defines a group of related options in
a drop-down list.
<option> It defines an option in a drop-down list.
<button> It defines a clickable button.
HTML <form> element
• Syntax:
• <form>
• //Form elements
• </form>
<html>
• <body>
• <form>
• Enter your name <br>
• <input type="text" name="username">
• </form>
• </body>
• </html>
• <form>
• First Name: <input type="text" name="firstn
ame"/> <br/>
• Last Name: <input type="text" name="lastn
ame"/> <br/>
• </form>
HTML <textarea> tag in form
• The <textarea> tag in HTML is used to insert multiple-line text in a form. The size
of <textarea> can be specify either using "rows" or "cols" attribute or by CSS.
• Example:
• <!DOCTYPE html>
• <html>
• <head>
• <title>Form in HTML</title>
• </head>
• <body>
• <form>
• Enter your address:<br>
• <textarea rows="2" cols="20"></textarea>
• </form>
• </body>
• </html>
Label Tag in Form
• <form>
• <label for="firstname">First Name: </
label> <br/>
• <input type="text" id="firstname" name=
"firstname"/> <br/>
• <label for="lastname">Last Name: </label>
• <input type="text" id="lastname" name="
lastname"/> <br/>
• </form>
HTML Password Field Control
• The password is not visible to the user in
password field control.
• <form>
• <label for="password">Password: </label>
• <input type="password" id="password"
name="password"/> <br/>
• </form>
HTML Email Field Control
• It validates the text for correct email address.
You must use @ and . in this field.
• <form>
• <label for="email">Email: </label>
• <input type="email" id="email" name=
"email"/> <br/>
• </form>
Radio Button Control
 The radio button is used to select one option from multiple
options. It is used for selection of gender, quiz questions etc.
• If you use one name for all the radio buttons, only one radio
button can be selected at a time.
• Using radio buttons for multiple options, you can only
choose a single option at a time.
• <form>
• <label for="gender">Gender: </label>
• <input type="radio" id="gender" name="gender" v
alue="male"/>Male
• <input type="radio" id="gender" name="gender" v
alue="female"/>Female <br/>
• </form>
Checkbox Control
• The checkbox control is used to check multiple options from given checkboxes.
• <form>
• Hobby:<br>
• <input type="checkbox" id="cricket" name="cricket" value="cricket"/>
• <label for="cricket">Cricket</label> <br>
• <input type="checkbox" id="football" name="football" value="football"/
>
• <label for="football">Football</label> <br>
• <input type="checkbox" id="hockey" name="hockey" value="hockey"/
>
• <label for="hockey">Hockey</label>
• </form>
• Note: These are similar to radio button except it can choose multiple options at a
time and radio button can select one button at a time, and its display.

More Related Content

PPTX
HTML_HEADER PART TAGS .pptx
HARIPRIYAV25
 
PPTX
Introduction to html
Himanshu Pathak
 
PPTX
Learn html Basics
McSoftsis
 
PPTX
Html starting
Rahul Dihora
 
PPTX
learnhtmlbyvipuladissanayake-170516061515 (1).pptx
ManuAbraham17
 
PPTX
BITM3730Week1.pptx
MattMarino13
 
PPTX
Introduction to Web Techniques_Key componenets_HTML Basics
DeepakUlape2
 
HTML_HEADER PART TAGS .pptx
HARIPRIYAV25
 
Introduction to html
Himanshu Pathak
 
Learn html Basics
McSoftsis
 
Html starting
Rahul Dihora
 
learnhtmlbyvipuladissanayake-170516061515 (1).pptx
ManuAbraham17
 
BITM3730Week1.pptx
MattMarino13
 
Introduction to Web Techniques_Key componenets_HTML Basics
DeepakUlape2
 

Similar to web page.pptxb dvcdhgdhdbdvdhudvehsusvsudb (20)

PPTX
Html 5
DanellaPatrick
 
PDF
web development.pdf
BagHarki
 
PPTX
Web Development - Lecture 3
Syed Shahzaib Sohail
 
PPT
html
tumetr1
 
PPTX
HTML Basics, Web Development Part-1 .pptx
Farzana Younas
 
PPTX
Chapter 2 - Introduction to HTML (Basic Structures and Syntax).pptx
marjunegabon07
 
PDF
PPT-203105353-1.pdf
PINTUCHAUHAN8
 
PPTX
2. HTML Basic unit2 fundamentals of computer
travelwithlifezindgi
 
PPTX
htmlbcjdkkdkcjcjcjfkjccjckcjcjc_doc1.pptx
DSAISUBRAHMANYAAASHR
 
PPT
HTML & CSS.ppt
vaseemshaik21
 
PPTX
Html and css
Sukrit Gupta
 
PPT
html and css- 23091 3154 458-5d4341a0.ppt
ahoveida
 
PPTX
Web Design HTML for beginners and advanced learners .pptx
mark575496
 
PPTX
HTML
Toni Kolev
 
PPTX
HTML5 2019
rfojdar
 
PPTX
Introduction to html
vinita mathur
 
PPT
Web forms and html (lect 1)
Salman Memon
 
PPSX
Html introduction
Dalia Elbadry
 
web development.pdf
BagHarki
 
Web Development - Lecture 3
Syed Shahzaib Sohail
 
html
tumetr1
 
HTML Basics, Web Development Part-1 .pptx
Farzana Younas
 
Chapter 2 - Introduction to HTML (Basic Structures and Syntax).pptx
marjunegabon07
 
PPT-203105353-1.pdf
PINTUCHAUHAN8
 
2. HTML Basic unit2 fundamentals of computer
travelwithlifezindgi
 
htmlbcjdkkdkcjcjcjfkjccjckcjcjc_doc1.pptx
DSAISUBRAHMANYAAASHR
 
HTML & CSS.ppt
vaseemshaik21
 
Html and css
Sukrit Gupta
 
html and css- 23091 3154 458-5d4341a0.ppt
ahoveida
 
Web Design HTML for beginners and advanced learners .pptx
mark575496
 
HTML5 2019
rfojdar
 
Introduction to html
vinita mathur
 
Web forms and html (lect 1)
Salman Memon
 
Html introduction
Dalia Elbadry
 
Ad

Recently uploaded (20)

PPTX
Google SGE SEO: 5 Critical Changes That Could Wreck Your Rankings in 2025
Reversed Out Creative
 
PPT
Introduction to dns domain name syst.ppt
MUHAMMADKAVISHSHABAN
 
PPTX
Different Generation Of Computers .pptx
divcoder9507
 
PPTX
Blue and Dark Blue Modern Technology Presentation.pptx
ap177979
 
PPTX
Generics jehfkhkshfhskjghkshhhhlshluhueheuhuhhlhkhk.pptx
yashpavasiya892
 
PDF
Cybersecurity Awareness Presentation ppt.
banodhaharshita
 
PDF
The Internet of Things (IoT) refers to a vast network of interconnected devic...
chethana8182
 
PDF
PDF document: World Game (s) Great Redesign.pdf
Steven McGee
 
PPTX
EthicalHack{aksdladlsfsamnookfmnakoasjd}.pptx
dagarabull
 
PDF
KIPER4D situs Exclusive Game dari server Star Gaming Asia
hokimamad0
 
PPTX
Slides Powerpoint: Eco Economic Epochs.pptx
Steven McGee
 
PPTX
Crypto Recovery California Services.pptx
lionsgate network
 
PPTX
The Latest Scam Shocking the USA in 2025.pptx
onlinescamreport4
 
PDF
Slides: PDF Eco Economic Epochs for World Game (s) pdf
Steven McGee
 
PDF
Generative AI Foundations: AI Skills for the Future of Work
hemal sharma
 
PPTX
SEO Trends in 2025 | B3AITS - Bow & 3 Arrows IT Solutions
B3AITS - Bow & 3 Arrows IT Solutions
 
PDF
Data Protection & Resilience in Focus.pdf
AmyPoblete3
 
PPT
Transformaciones de las funciones elementales.ppt
rirosel211
 
PPTX
Unlocking Hope : How Crypto Recovery Services Can Reclaim Your Lost Funds
lionsgate network
 
PPTX
Microsoft PowerPoint Student PPT slides.pptx
Garleys Putin
 
Google SGE SEO: 5 Critical Changes That Could Wreck Your Rankings in 2025
Reversed Out Creative
 
Introduction to dns domain name syst.ppt
MUHAMMADKAVISHSHABAN
 
Different Generation Of Computers .pptx
divcoder9507
 
Blue and Dark Blue Modern Technology Presentation.pptx
ap177979
 
Generics jehfkhkshfhskjghkshhhhlshluhueheuhuhhlhkhk.pptx
yashpavasiya892
 
Cybersecurity Awareness Presentation ppt.
banodhaharshita
 
The Internet of Things (IoT) refers to a vast network of interconnected devic...
chethana8182
 
PDF document: World Game (s) Great Redesign.pdf
Steven McGee
 
EthicalHack{aksdladlsfsamnookfmnakoasjd}.pptx
dagarabull
 
KIPER4D situs Exclusive Game dari server Star Gaming Asia
hokimamad0
 
Slides Powerpoint: Eco Economic Epochs.pptx
Steven McGee
 
Crypto Recovery California Services.pptx
lionsgate network
 
The Latest Scam Shocking the USA in 2025.pptx
onlinescamreport4
 
Slides: PDF Eco Economic Epochs for World Game (s) pdf
Steven McGee
 
Generative AI Foundations: AI Skills for the Future of Work
hemal sharma
 
SEO Trends in 2025 | B3AITS - Bow & 3 Arrows IT Solutions
B3AITS - Bow & 3 Arrows IT Solutions
 
Data Protection & Resilience in Focus.pdf
AmyPoblete3
 
Transformaciones de las funciones elementales.ppt
rirosel211
 
Unlocking Hope : How Crypto Recovery Services Can Reclaim Your Lost Funds
lionsgate network
 
Microsoft PowerPoint Student PPT slides.pptx
Garleys Putin
 
Ad

web page.pptxb dvcdhgdhdbdvdhudvehsusvsudb

  • 2. Structure of a website • website is mostly made up of numerous webpages. These webpages are HTML documents that are stored in a directory on a domain. The domain should not be confused with the website. The domain is the internet address via which the content of the website can be called up. • HTML is not a programming language but a page description language:
  • 3. • In the code, it is defined which element is to be displayed at which point. This means in the design of a website, there is not a picture used for the entire site, rather it is defined in the code how the font, the colors and, of course, possible pictures or videos are to be arranged – depending on what device is being used (e.g. desktop computer or smartphone) to access it.
  • 4. HTML • HTML stands for HyperText Markup Language. • HTML is used to create web pages and web applications. • HTML is widely used language on the web. • We can create a static website by HTML only.
  • 5. HTML text Editors • An HTML file is a text file, so to create an HTML file we can use any text editors. • Text editors are the programs which allow editing in a written text, hence to create a web page we need to write our code in some text editor(Notepad++, Sublime Text, Vim, etc. )
  • 6. Building blocks of HTML • An HTML document consist of its basic building blocks which are • Tags: An HTML tag surrounds the content and apply meaning to it. It is written between < and > brackets. • Attribute: An attribute in HTML provides extra information about the element, and it is applied within the start tag. An HTML attribute contains two fields: name & value
  • 7. Syntax • <tag name attribute_name= " attr_value"> con tent </ tag name> • Elements: An HTML element is an individual component of an HTML file. In an HTML file, everything written within tags are termed as HTML elements(heading,paragraph,list,table,link and so on).
  • 8. All HTML tags must enclosed within < > these brackets. Every tag in HTML perform different tasks. If you have used an open tag <tag>, then you must use a close tag </tag> (except some tags) Syntax • <tag> content </tag>
  • 10. • Void element: All the elements in HTML do not require to have start tag and end tag, some elements does not have content and end tag such elements are known as Void elements or empty elements. These elements are also called as unpaired tag. • Some Void elements are <br> (represents a line break) , <hr>(represents a horizontal line), etc.
  • 11. • <!DOCTYPE> • <html> • <head> • <title>Web page title</title> • </head> • <body> • <h1>Write Your First Heading</h1> • <p>Write Your First Paragraph.</p> • </body> • </html>
  • 12. • <html> • <head> • <title>The basic building blocks of HTML</title> • </head> • <body> • <h2>The building blocks</h2> • <p>This is a paragraph tag</p> • <p style="color: red">The style is attribute of paragrap h tag</p> • <span>The element contains tag, attribute and content </span> • </body> • </html>
  • 13. HTML Attribute • HTML attributes are special words which provide additional information about the elements or attributes are the modifier of the HTML element. • Each element or tag can have attributes, which defines the behavior of that element. • Attributes should always be applied with start tag. • The Attribute should always be applied with its name and value pair. • The Attributes name and values are case sensitive, and it is recommended by W3C that it should be written in Lowercase only. Syntax • <element =attribute name:value">content</element> • <p style=“color:red”>the first paragraph of the document</p>
  • 14. Example of attri. • <html> • <head> • </head> • <body> • <h1> This is Style attribute</h1> • <p style="height: 50px; color: blue">It will add style pr operty in element</p> • <p style="color: red">It will change the color of content </p> • </body> • </html>
  • 15. Example: • <html> • <head> • </head> • <body> • <div style="background-color: lightblue">This is first d div> • <div style="background- color: lightgreen">This is second div</div> • <p style="background- color: pink">This is a block level element</p> • </body> • </html>
  • 16. HTML Formatting • is a process of formatting text for better look and feel. HTML provides us ability to format text without using CSS. There are many formatting tags in HTML. These tags are used to make text bold, italicized, or underlined. • In HTML the formatting tags are divided into two categories: • 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
  • 17. HTML Heading • A HTML heading or HTML h tag can be defined as a title or a subtitle which you want to display on the webpage. When you place the text within the heading tags <h1>.........</h1>, it is displayed on the browser in the bold format and size of the text depends on the number of heading. • There are six different HTML headings which are defined with the <h1> to <h6> tags, from highest level h1 (main heading) to the least level h6 (least important heading).
  • 18. 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. • href attribute of HTML & it points out the destination page. • The syntax of HTML anchor tag is given below. • <a href = "..........."> Link Text </a>
  • 19. • <html> • <head> • <title></title> • </head> • <body> • <a href="https:// www.youtube.com/" target="_blank"> this-link </a> • <a href=“C:UsersHpDesktophi.html>click here</a> • </body> • </html>
  • 20. Appearance of HTML anchor tag • An unvisited link is displayed underlined and blue. • A visited link displayed underlined and purple. • An active link is underlined and red. HTML Image • HTML img tag is used to display image on the web page. HTML img tag is an empty tag that contains attributes only, closing tags are not used in HTML image element. • <img src="good_morning.jpg" alt="Good Morning Fri ends"/>
  • 21. Attributes of HTML img tag • 1) src(source) • 2) alt(alternative) • 3) width • 4) height Example: • <img src="animal.jpg" height="180" width="300 " alt="animal image">
  • 22. How to get image from another directory/folder? • <img src="E:/images/ animal.png" height="180" width="300" alt="animal image" > Use <img> tag as a link • We can also link an image with other page or we can use an image as a link. To do this, put <img> tag inside the <a> tag. • Example: • <a href="https://www.javatpoint.com/what-is- robotics"><img src="robot.jpg" height="100" width="100" ></a>
  • 23. HTML Table • HTML table tag is used to display data in tabular form (row * column). There can be many columns in a row. • We can create a table to display data in tabular form, using <table> element, with the help of <tr> , <td>, and <th> elements. • In Each table, table row is defined by <tr> tag, table header is defined by <th>, and table data is defined by <td> tags. • HTML tables are used to manage the layout of the page e.g. header section, navigation bar, body content, footer section etc. But it is recommended to use div tag over table to manage the layout of the page .
  • 24. Tag Description <table> It defines a table. <tr> It defines a row in a table. <th> It defines a header cell in a table. <td> It defines a cell in a table. <caption> It defines the table caption. <colgroup> It specifies a group of one or more columns in a table for formatting. <col> It is used with <colgroup> element to specify column properties for each column. <tbody> It is used to group the body content in a table. <thead> It is used to group the header content in a table. <tfooter> It is used to group the footer content
  • 25. Example • <table> • <tr><th>First_Name</th><th>Last_Name</ th><th>Marks</th></tr> • <tr><td>Sonoo</td><td>Jaiswal</td><td>60</td></ tr> • <tr><td>James</td><td>William</td><td>80</ td></tr> • <tr><td>Swati</td><td>Sironi</td><td>82</td></ tr> • <tr><td>Chetna</td><td>Singh</td><td>72</td></ tr> • </table>
  • 26. • 1) HTML Border attribute • You can use border attribute of table tag in HTML to specify border. But it is not recommended now. • <table border="1"> • <tr><th>First_Name</ th><th>Last_Name</th><th>Marks</th></ tr> • <tr><td>Sonoo</td><td>Jaiswal</ td><td>60</td></tr> • </table>
  • 27. HTML Lists • Ordered List or Numbered List (ol) • Unordered List or Bulleted List (ul) • Description List or Definition List (dl 1. Ordered List or Numbered List (ol) • <ol> • <li>Aries</li> • <li>Bingo</li> • <li>Leo</li> • <li>Oracle</li> • </ol>
  • 28. 2. Unordered List or Bulleted List (ul) • <ul> • <li>Aries</li> • <li>Bingo</li> • <li>Leo</li> • <li>Oracle</li> • </ul>
  • 29. 3. Description List or Definition List (dl) • HTML Description List or Definition List displays elements in definition form like in dictionary. The <dl>, <dt> and <dd> tags are used to define description list. • The 3 HTML description list tags are given below: • <dl> tag defines the description list. • <dt> tag defines data term. • <dd> tag defines data definition (description). • </dl>
  • 30. HTML Form • An HTML form is a section of a document which contains controls such as text fields, password fields, checkboxes, radio buttons, submit button, menus etc. • An HTML form facilitates the user to enter data that is to be sent to the server for processing such as name, email address, password, phone number, etc.
  • 31. Tag Description <form> It defines an HTML form to enter inputs by the used side. <input> It defines an input control. <textarea> It defines a multi-line input control. <label> It defines a label for an input element. <fieldset> It groups the related element in a form. <select> It defines a drop-down list. <optgroup> It defines a group of related options in a drop-down list. <option> It defines an option in a drop-down list. <button> It defines a clickable button.
  • 32. HTML <form> element • Syntax: • <form> • //Form elements • </form> <html> • <body> • <form> • Enter your name <br> • <input type="text" name="username"> • </form> • </body> • </html>
  • 33. • <form> • First Name: <input type="text" name="firstn ame"/> <br/> • Last Name: <input type="text" name="lastn ame"/> <br/> • </form>
  • 34. HTML <textarea> tag in form • The <textarea> tag in HTML is used to insert multiple-line text in a form. The size of <textarea> can be specify either using "rows" or "cols" attribute or by CSS. • Example: • <!DOCTYPE html> • <html> • <head> • <title>Form in HTML</title> • </head> • <body> • <form> • Enter your address:<br> • <textarea rows="2" cols="20"></textarea> • </form> • </body> • </html>
  • 35. Label Tag in Form • <form> • <label for="firstname">First Name: </ label> <br/> • <input type="text" id="firstname" name= "firstname"/> <br/> • <label for="lastname">Last Name: </label> • <input type="text" id="lastname" name=" lastname"/> <br/> • </form>
  • 36. HTML Password Field Control • The password is not visible to the user in password field control. • <form> • <label for="password">Password: </label> • <input type="password" id="password" name="password"/> <br/> • </form>
  • 37. HTML Email Field Control • It validates the text for correct email address. You must use @ and . in this field. • <form> • <label for="email">Email: </label> • <input type="email" id="email" name= "email"/> <br/> • </form>
  • 38. Radio Button Control  The radio button is used to select one option from multiple options. It is used for selection of gender, quiz questions etc. • If you use one name for all the radio buttons, only one radio button can be selected at a time. • Using radio buttons for multiple options, you can only choose a single option at a time. • <form> • <label for="gender">Gender: </label> • <input type="radio" id="gender" name="gender" v alue="male"/>Male • <input type="radio" id="gender" name="gender" v alue="female"/>Female <br/> • </form>
  • 39. Checkbox Control • The checkbox control is used to check multiple options from given checkboxes. • <form> • Hobby:<br> • <input type="checkbox" id="cricket" name="cricket" value="cricket"/> • <label for="cricket">Cricket</label> <br> • <input type="checkbox" id="football" name="football" value="football"/ > • <label for="football">Football</label> <br> • <input type="checkbox" id="hockey" name="hockey" value="hockey"/ > • <label for="hockey">Hockey</label> • </form> • Note: These are similar to radio button except it can choose multiple options at a time and radio button can select one button at a time, and its display.