HTML Ppts
HTML Ppts
TOPIC SPECIFICATION
1. Introduction to HTML
2. Document Heading
Build Your Web Site from Start to Finish 3. HTML Text Formatting Tags
4. HTML List
5. HTML table
6. HTML links
FUNDAMENTALS OF HTML 7. Images and other page elements
8. Frames
9. Forms
SGML
Standard Generalized Markup Language
Supports Simple text, it don’t support Graphics Features
1
29-Jun-15
2
29-Jun-15
<head>
<body>
• Will contain the following tags
– <title> • All web page content that we want the
• Tells browser what to put in the title bar of
page viewer to see on the web page is
– <script> written here
• Tells browser what, if any, scripting language • Attributes like
is being used
– <meta> – <background>
• Designates meta tags for search engines – <bgcolor>
– <link> – <text>
• Directs other pages appearance
– <style>
• Use in Cascading Style Sheet (CSS)
3
29-Jun-15
• Example:
<html>
<head>
<title>Web Authoring</title>
</head>
<body>
<p>HTML is easy!!</p>
</body>
</html>
4
29-Jun-15
5
29-Jun-15
6
29-Jun-15
7
29-Jun-15
8
29-Jun-15
9
29-Jun-15
10
29-Jun-15
Types of Lists
• Lists may be used for a piece of information
and for providing a straightforward index to
Creating Lists the site.
• HTML provides three types of lists.
– Unordered Lists - <ul>
– Ordered Lists - <ol>
– Definition Lists - <dl>
11
29-Jun-15
Another Example
Here is an ordered list using small
Roman values:
<ol type=”i”>
<li>Point number one </li>
<li>Point number two</li>
<li>Point number three</li>
</ol>
12
29-Jun-15
Nesting Lists
• We can nest lists inside other lists.
• For example, we might want a numbered
list with separate points corresponding to
one of the list items. Each list will be
numbered separately . And each new list
should be placed inside a <li> element
13
29-Jun-15
Example
<ol>
<li>Speed
<ul>
<li>1.5 Ghz
<li>2.2 Ghz
<li>2.7 Ghz
</ul>
<li>RAM
<ul>
<li>128 MB
<li>256 MB
<li>512 MB
<li>1 GB
</ul>
<li>120 GB
<li>320 GB <table> Tag
<li>External Disks
<ul>
<li>CD-ROM
<li>CD-Writer
<li>Combo Driver
<li>DVD Driver
</ul>
<li>Monitor
<ul>
<li>15"
<li>17"
</ul>
</ol>
14
29-Jun-15
<TABLE> Attributes
<TR> - Creating a Table Row
• BORDER : To display a table with borders, we will have to use the
border attribute.
• CELLSPACING : This attribute allows control over the space used • Creates a row in a table. Contains multiple <TD> or
between cells in a table. The value should be a pixel value.
• CELLPADDING : This attribute allows control over the space <TH> elements.
inserted between the cell data and cell wall in a table. The value
should be a pixel value. • Attributes
• WIDTH : This attribute is used to describe the desired width of this – Align : Specifies the horizontal alignment of the text in
table, either as an absolute width in pixels, or a percentage of
document width. this table row. Set to LEFT, CENTER,RIGHT.
• HEIGHT : This attribute describes the height of the table, either as a
particular pixel value, or as a percentage of the display window. – Bgcolor : Sets the background color of the table cells.
• ALIGN : It allows a table to be aligned to the left or right of the – Bordercolor : Sets the external border color for the row.
page, allowing text to flow around the table.
• BGCOLOR : It allows the background color of the table to be – Valign :Sets the vertical alignment of the data in this row.
specified, using either the specified color names, or a rrggbb hex Sets to TOP,MIDDLE,BOTTOM.
triplet.
• BORDERCOLOR : This attribute used to set the border color of the
table.
15
29-Jun-15
Frames
• With frames, we can display more than one HTML
document in the same browser window. Each HTML
document is called a frame, and each frame is
Working with Frames independent of the others.
• Frames divide a browser window into several separate
<Frameset> , <Frame> Tag pieces or panes, each pane containing a separate HTML
page.
• One of the key advantages of frames is that we can load
and reload individual panes without having to reload the
entire contents of the browser window.
• A collection of frames in the browser window is known as
a frameset.
16
29-Jun-15
17
29-Jun-15
What is a FORM?
• Forms provide a means of
submitting information from the
Working with Forms client to the server. Using Form ,
we will be able to handle HTML
<FORM> , <INPUT> Tags
controls like textfields , buttons ,
textareas , checkboxes.
18
29-Jun-15
What is a FORM?
<FORM> - Creating HTML Forms
• HTML forms are used to create GUIs on Web
pages • Creates an HTML form; used to enclose HTML
– Usually the purpose is to ask the user for information controls like buttons and textfields.
– The information is then sent back to the server • Attributes :
• A form is an area that can contain form elements – Action : Gives the URL that will handle the form data
when the Submit button is clicked.
– The syntax is: <form parameters> ...form elements... </form> – Method : Indicates a method or protocol for sending
– Form elements include: buttons, checkboxes, text fields, data to the target action URL. Possible values are
radio buttons, drop-down menus, etc GET(default) / POST.
• Other kinds of HTML tags can be mixed in with the form elements – Name : Gives a name to the form so we can
– A form usually contains a Submit button to send the reference it in code.
information in he form elements to the server – Target : Indicates a named frame for the browser to
– The form’s parameters tell JavaScript how to send the display the form results in.
information to the server.
19
29-Jun-15
Buttons Checkboxes
• A submit button:
<input type="submit" name="Submit" value="Submit"> • A checkbox:
• A reset button: <input type="checkbox" name="chkbx”
<input type="reset" name="Submit2" value="Reset">
• A plain button: value="checkbox" checked>
<input type="button" name="Submit3" value="Push Me">
• If two or more radio buttons have the same name, the user
can only select one of them at a time • Additional arguments:
– This is how you make a radio button “group”
– size: the number of items visible in the list
• If you ask for the value of that name, you will get the value (default is "1")
specified for the selected radio button
– multiple: if set to "true", any number of items
• As with checkboxes, radio buttons do not contain any text may be selected (default is "false")
20
29-Jun-15
21