HTML

September 7, 2022 | Author: Anonymous | Category: N/A
Share Embed Donate


Short Description

Download HTML...

Description

 

HTML Introduction What is HTML? HTML is a markup markup language  language for describing describing web  web documents (web pages). •

HTML stands for Hyper Text Markup Language



A markup language is a set of markup tags



HTML documents are described by HTML tags



Eac HTML tag describes describes different  different document content

HTML Example A small HTML document:  and  and  describes  describes a eading



Te text between  and  and  describes  describes a paragrap

#sing tis description$ a web browser can display a document wit a eading and a paragrap.

HTML Ta$s HTML tags are ke!#rds ke!#rds (tag  (tag names) surrounded by angle brackets% brackets%

. Te HTML document itself begins wit  and  and ends wit .. Te "isible part of te HTML document is between  and  and ..

Example  to  to  tags%  tags%

Example p$3  alt=3W5.chools+com3 alt=3W5.chools+com3  -idth=3(103 -idth=3(103  hei$ht= hei$ht=3(03 3(03 #

HTML Elements HTML elements are written wit a start start tag$  tag$ wit an end end tag$  tag$ wit te cntent cntent in  in between%

&tagname tagname' 'content content& & tagname  tagname' ' Te HTML element element is  is e"eryting from te start tag to te end tag%

&p'My first HTML paragrap.& paragrap. & p  p' ' )tart tag

Element cntent

End tag

&0'

My +irst Heading

&0'

&p'

My first paragrap.

&p'

&br'

,ome HTML elements do not a"e an end tag.

 

6ested HTML Elements HTML elements can be nested (elements can contain elements). All HTML documents consist of nested HTML elements. Tis example contains < HTML elements%

Example  element  element defines te #hle dcument. dcument. *t as a start start tag  tag &tml' and an end end tag  tag &tml'. Te element cntent cntent is  is anoter HTML element (te &body' element).

html# # p$3 src=3-5schools+>p$3  alt=3W5.chools+com3 alt=3W5.chools+com3  -idth=3(103 -idth=3(103  hei$ht= hei$ht=3(03 3(03 # Try it 4ourself !

We .u$$est: Al-a's 2se Lo-ercase Attri&utes Te HTML7 standard does not reuire lower case attribute names.

 

Te title attribute can be written wit upper or lower case like Title Title andor  andor T0TLE T0TLE.. 56 recmmends recmmends lowercase  lowercase in HTML element  element defines a line break. break. #se &br' if you want a line break (a new line) witout starting a new paragrap%

Example s usemap attribute and creates a relationsip between te image and te map. Te &map' tag contains a number of &area' tags$ tat defines te clickable areas in te imageDmap%

Example im$  src=3planets+$i3 src=3planets+$i3  alt=3"lanets3 alt=3"lanets3  usemap= usemap=3planetmap3 3planetmap3  st'le=3-idth:( st'le=3-idth:( s element usemap usemap attribute  attribute to point to an imageD map

Loading images takes time. Large images can slow down your page. #se images caref

 Test  T est oursel oursel -ith E Ex xercises! ercises! !   Exercise 9 ! !   Exercise 6 ! !   Exercise < ! !   Exercise 7 ! !   Exercise F ! Exercise 0 !

HTML Ima$e Ta$s Tag

Descriptin

&img'

3efines an image

&map'

3efines an imageDmap

 

&area'

3efines a clickable area inside an imageDmap

HTML Lists B /re"ious ?ext apter !

Example o an unordered list and an ordered list in HTML: 2nordered List: •

*tem



*tem



*tem



*tem

Ordered List: 0. +irs +irstt iittem 9. ,eco ,econd nd it item em 6. Tird ird it item em  defines t!pe*+submit+> defines a button for submitting submitting form  form input to a (rm6handler (rm6handler.. Te formDandler is typically a ser"er page wit a script for processing input data. Te formDandler is specified in te form>s action attribute%

Example orm  action=3actionJpa$e+php3 action=3actionJpa$e+php3# #
View more...

Comments

Copyright ©2017 KUPDF Inc.
SUPPORT KUPDF