Download presentation
Presentation is loading. Please wait.
Published byGerald Summers Modified over 8 years ago
1
Presented By Presented By Tanveera Akhter Class:CA 2 nd year Dated:12/12/3456 Dept of Comp. Science
2
WWW use classical client / server architecture HTTP is text-based request-response protocol 2 Page request Client running a Web Browser Server running Web Server Software (IIS, Apache, etc.) Server response HTTP HTTP
3
Web pages are text files containing HTML HTML – H yper T ext M arkup L anguage A notation for describing document structure (semantic markup) formatting (presentation markup) Looks (looked?) like: A Microsoft Word document The markup tags provide information about the page content structure 3
4
An HTML file must have an.htm or.html file extension HTML files can be created with text editors: NotePad, NotePad ++, PSPad Or HTML editors (WYSIWYG Editors): Microsoft FrontPage Macromedia Dreamweaver Netscape Composer Microsoft Word Visual Studio 4
5
Text, Images
6
HTML is comprised of “elements” and “tags” Begins with and ends with Begins with and ends with Elements (tags) are nested one inside another: Tags have attributes: HTML describes structure using two main sections: and HTML describes structure using two main sections: and 6
7
The HTML source code should be formatted to increase readability and facilitate debugging. Every block element should start on a new line. Every nested (block) element should be indented. Browsers ignore multiple whitespaces in the page source, so formatting is harmless. For performance reasons, formatting can be sacrificed 7
8
8 <html> My First HTML Page My First HTML Page This is some text... This is some text... </html> test.html
9
<html> My First HTML Page My First HTML Page This is some text... This is some text... </html> 9 Opening tag Closing tag An HTML element consists of an opening tag, a closing tag and the content inside.
10
<html> My First HTML Page My First HTML Page This is some text... This is some text... </html> 10 HTML header
11
<html> My First HTML Page My First HTML Page This is some text... This is some text... </html> 11 HTML body
12
Hyperlink Tags Image Tags Text formatting tags 12 <a href="http://www.telerik.com/" title="Telerik">Link to Telerik Web site title="Telerik">Link to Telerik Web site This text is emphasized. This text is emphasized. new line new line This one is more emphasized. This one is more emphasized.
13
13 <html><head> Simple Tags Demo Simple Tags Demo </head><body> <a href="http://www.telerik.com/" title= "Telerik site">This is a link. "Telerik site">This is a link. Bold and italic text. Bold and italic text.</body></html> some-tags.html
14
Tags can have attributes Attributes specify properties and behavior Example: Few attributes can apply to every element: id, style, class, title The id is unique in the document Content of title attribute is displayed as hint when the element is hovered with the mouse Some elements have obligatory attributes 14 Attribute alt with value " logo "
15
Heading Tags (h1 – h6) Paragraph Tags Sections: div and span 15 This is my first paragraph This is my first paragraph This is my second paragraph This is my second paragraph Heading 1 Heading 1 Sub heading 2 Sub heading 2 Sub heading 3 Sub heading 3 This is a div This is a div
16
<html> Headings and paragraphs Headings and paragraphs Heading 1 Heading 1 Sub heading 2 Sub heading 2 Sub heading 3 Sub heading 3 This is my first paragraph This is my first paragraph This is my second paragraph This is my second paragraph This is a div This is a div </html> 16 headings.html
17
Contains information that doesn’t show directly on the viewable page Starts after the declaration Begins with and ends with Begins with and ends with Contains mandatory single tag Can contain some other tags, e.g. 17
18
Title should be placed between and tags Used to specify a title in the window title bar Search engines and people rely on titles 18 My first web page My first web page
19
Comments can exist anywhere between the tags Comments start with Comments start with 19 logo logo...
20
The section describes the viewable portion of the page Starts after the section Begins with and ends with Begins with and ends with 20 <html> Test page Test page </html>
21
Text formatting tags modify the text between the opening tag and the closing tag Ex. Hello makes “Hello” bold bold italicized underlined Sample superscript Sample subscript strong emphasized Preformatted text Quoted text block Deleted text – strike through 21
22
22 <html> Page Title Page Title Notice Notice This is a sample Web page. This is a sample Web page. Next paragraph: Next paragraph: preformatted. preformatted. More Info More Info Specifically, we’re using XHMTL 1.0 transitional. Specifically, we’re using XHMTL 1.0 transitional. Next line. Next line. </html> text-formatting.html
23
Link to a document called form.html on the same server in the same directory: Link to a document called parent.html on the same server in the parent directory: Link to a document called cat.html on the same server in the subdirectory stuff : 23 Fill Our Form Fill Our Form Parent Parent Catalog Catalog
24
Link to another location in the same document: Link to a specific location in another document: 24 Go to Introduction Go to Introduction... Introduction Introduction Go to Section 3.1.1 Go to Section 3.1.1... 3.1.1. Technical Background 3.1.1. Technical Background </div>
25
Fill Our Form Fill Our Form Parent Parent Catalog Catalog BASD BASD Please report bugs here (by e-mail only) Please report bugs here (by e-mail only) Switch to English version Switch to English version hyperlinks.html 25
26
26 Table of Contents Table of Contents Introduction Introduction Some background Some background Project History Project History...the rest of the table of contents... Introduction Introduction... Section 1 follows here... Some background Some background... Section 2 follows here... Project History Project History... Section 2.1 follows here... links-to-same-document.html
27
27 Table of Contents Table of Contents Introduction Introduction Some background Some background Project History Project History...the rest of the table of contents... Introduction Introduction... Section 1 follows here... Some background Some background... Section 2 follows here... Project History Project History... Section 2.1 follows here... links-to-same-document.html
28
Inserting an image with tag: Image attributes: Example: src Location of image file (relative or absolute) alt Substitute text for display (e.g. in text mode) height Number of pixels of the height width Number of pixels of the width border Size of border, 0 for no border 28
29
: Draws a horizontal rule (line): : Deprecated! 29 Hello World! Hello World! Font3 Font3 Font+4 Font+4
30
30 <html> Miscellaneous Tags Example Miscellaneous Tags Example Hello World! Hello World! Font3 Font3 Font+4 Font+4 </html> misc.html
31
Wish You all the Best 31
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.