Basic HTML - PowerPoint PPT Presentation

1 / 37
About This Presentation
Title:

Basic HTML

Description:

Same codes as for background color. Attribute of the body tag, too ... With a border=0, you can easily create columns that are lined up and leave as ... – PowerPoint PPT presentation

Number of Views:30
Avg rating:3.0/5.0
Slides: 38
Provided by: Kathleen303
Category:
Tags: html | attribute | basic

less

Transcript and Presenter's Notes

Title: Basic HTML


1
Basic HTML
  • By Kathy Schrock

2
Part 1 Basic Web Page Production
3
Basic Web page creation
  • Basic HTML tags
  • Heading tags
  • Paragraph and break tags
  • Text alignment
  • Background color
  • Text color
  • Horizontal rules
  • Bold and italic

4
Basic HTML tags
  • ltHTMLgt
  • ltHEADgt
  • ltTITLEgt lt/TITLEgt
  • lt/HEADgt
  • ltBODYgt
  • lt/BODYgt
  • lt/HTMLgt

5
Heading tags
  • Used to denote main headings and subheadings go
    from 1 to 6
  • Show relative importance of information
  • ltH1gtThis is H1lt/H1gt This is H1
  • ltH2gtThis is H2lt/H2gt This is H2
  • ltH3gtThis is H3lt/H3gt This is H3
  • ltH4gtThis is H4lt/H4gt This is H4

6
Paragraph and break tags
  • ltPgtlt/Pgt surround a paragraph of info
  • Skips a line and starts a new paragraph
  • ltBRgt (single-sided tag)
  • Starts the next word on the next line
  • No space left between lines

7
Text alignment
  • The default is that all text is left-aligned
  • To align paragraphs, you can add to the paragraph
    tag ltP aligncentergt lt/Pgt
  • To center whole blocks of text, just use ltCENTERgt
    lt/CENTERgt

8
Background color
  • Attribute added to the ltBODYgt tag
  • There are 16 color names you can add (red, blue,
    yellow, etc.) or you have to know the hexadecimal
    code
  • Examples
  • ltBODY BGCOLORredgt
  • ltBODY BGCOLOR00FFFFgt

9
Changing the text color
  • Same codes as for background color
  • Attribute of the body tag, too
  • Example would lead to a light blue page with dark
    purple text
  • ltBODY BGCOLOR00FFFF TEXT800000gt

10
The horizontal rule
  • Used to separate portions of a page
  • A one-sided tag
  • Can include a attribute
  • Example
  • ltHRgt
  • ltHR WIDTH50gt

11
Bold and italic
  • Used to emphasize text
  • Two-sided tags
  • Examples
  • ltBgtThis is boldlt/Bgt This is bold
  • ltIgtThis is italiclt/Igt This is italic

12
Part 2 Creating Lists
13
Lists
  • Bulleted lists
  • Numbered lists
  • Definition list

14
Bulleted (unordered) list
  • Good for drawing attention to items that are in
    no particular order
  • ltULgt
  • ltLIgtDogs Dogs
  • ltLIgtCats Cats
  • lt/ULgt

15
Numbered (ordered) lists
  • Great for describing sequential tasks or
    step-by-step procedures
  • ltOLgt
  • ltLIgtPhase 1 1. Phase 1
  • ltLIgtPhase 2 2. Phase 2
  • lt/OLgt

16
Definition list
  • Includes a statement of the word and followed by
    the definition
  • ltDLgt
  • ltDTgtCirrus Cirrus
  • ltDDgthigh wispy high wispy
  • ltDTgtNimbus Nimbus
  • ltDDgtdark dark
  • lt/DLgt

17
Part 3 Links and Navigation
18
Links and navigation
  • Relative links
  • Links in your own directory
  • Absolute links
  • Links located on another server
  • Changing link color

19
Relative links
  • Give you the name of the file you want to access
    in relation to the page you are on
  • If index.htm and page2.htm are in the same
    directory, the link on the index page to page 2
    would look like this
  • ltA HREFpage2.htmgtGo to page 2lt/Agt

20
Absolute links
  • Specify the entire URL to go to
  • ltA HREFhttp//cnn.com/gtGo to CNNlt/Agt

21
Changing the link color
  • If you change the background color, you may need
    to change the link color, too
  • ltBODY BGCOLOR00FFFF text000000
    linkFF0000 VLINK000000gt
  • Link is the color before choosing
  • Vlink is the color of the visited link

22
Part 4 Adding Graphics
23
Graphics for your page
  • Adding graphics to your page
  • Aligning graphics
  • Using graphics as links
  • Insert a background package

24
Adding graphics to your page
  • Two file formats
  • GIF for icons and line drawings
  • JPEG for photographs
  • Try to keep graphic files under 30k
  • Example of adding an apple picture
  • ltIMG SRCapple.gif altapplegt
  • The alt tag shows up in text browsers

25
Aligning graphics on a page
  • By default, the next line of text starts after
    the graphic image
  • By using the align tag, the text can be next to
    the graphic
  • ltIMG SRCapple.gif altapple ALIGNRIGHTgt

26
  • By using the alignright tag, you can move the
    picture to the right side of the text and put the
    text next to the picture rather than below it.

27
Using graphics as links
  • You may use a picture as a hypertext link
  • ltA HREFhttp//apple.com/gtltIMG SRCapple.gif
    altapplegtlt/Agt
  • This would give you the apple picture with a blue
    box around it to show that it is a link for no
    box, add BORDER0

28
Inserting a background picture
  • Background pictures should be small gifs that
    tile well
  • ltBODY BACKGROUNDbackground.gif text000000
    linkFF0000 VLINK000000gt

29
Part 5 Tables
30
Parts of a table
  • ltTABLEgt
  • ltTRgt
  • ltTDgt lt/TDgt
  • lt/TRgt
  • ltTRgt
  • ltTDgt lt/TDgt
  • lt/TRgt
  • lt/TABLEgt

31
Adding a border
  • Becomes an attribute of the TABLE tag
  • ltTABLE BORDER2gt
  • Gives your table a 2 pixel border
  • With a border0, you can easily create columns
    that are lined up and leave as much space as you
    wish

32
Changing the size of a table
  • By default, tables take up as much room as they
    need to hold the text
  • To make it a certain size, add the attribute to
    the TABLE tag
  • ltTABLE height100 width200gt
  • You can also use these in the ltTDgt tag to change
    the size of a particular cell

33
Adding a caption
  • Used to tell someone what the table means
  • Comes after the TABLE tag
  • ltCAPTIONgtlt/CAPTIONgt
  • Appears at the top of the table

34
Cell padding and spacing
  • Attributes of the TABLE tag
  • Cell spacing adds space between the cells without
    making the cells bigger
  • Cell padding adds space around the contents of a
    cell, pushing the walls of the cell outward
  • ltTABLE cellspacing2 cellpadding2gt

35
Table Headings
  • Used to put column headings in the table
  • ltTRgt
  • ltTHgtlt/THgtltTHgtlt/THgt
  • lt/TRgt

36
Spanning across columns or cells
  • ltTD colspan2gt would have data cover two columns
  • ltTD rowspan2gt would have data cover two rows

37
The End
Write a Comment
User Comments (0)
About PowerShow.com