Week 7: HTML Basics HNDIT11062 – Web Development.

Slides:



Advertisements
Similar presentations
HTML I. HTML Hypertext mark-up language. Uses tags to identify elements of a page so that a browser such as Internet explorer can render the page on a.
Advertisements

Basic Principles for Web Design Source:
Session 2 Introduction to HyperText Markup Language 4 (HTML 4) Matakuliah: M0114/Web Based Programming Tahun: 2005 Versi: 5.
HTML popo.
CREATED BY : VIRAL M.KORADIYA. Anchor elements are defined by the element. The element accepts several attributes, but either the Name or HREF attribute.
Internet Services and Web Authoring (CSET 226) Lecture # 5 HyperText Markup Language (HTML) 1.
HTML popo.
1 تقنيات الانترنت عال457 HTML. 2 HTML  HTML – HyperText Markup Language – The Language of Web Pages on the World Wide Web. HTML is a text formatting.
INTRODUCTION TO HYPERTEXT MARKUP LANGUAGE 1. Outline  Introduction  Markup Languages  Editing HTML  Common Tags  Headers  Text Styling  Linking.
Chapter 4 Marking Up With Html: A Hypertext Markup Language Primer.
Hypertext Markup Language. Platform: - Independent  This means it can be interpreted on any computer regardless of the hardware or operating system.
1 Outline 9.1Introduction 9.2Markup Languages 9.3Editing HTML 9.4Common Tags 9.5Headers 9.6Text Styling 9.7Linking 9.8Images 9.9Formatting Text With 9.10Special.
 2001 Deitel & Associates, Inc. All rights reserved. 1 Outline 9.1Introduction 9.2Markup Languages 9.3Editing HTML 9.4Common Tags 9.5Headers 9.6Text Styling.
HTML Computing Concepts HTML - An Introduction 1.
Marking Up With Html: A Hypertext Markup Language Primer
HTML BASIC
HTML: PART ONE. Creating an HTML Document  It is a good idea to plan out a web page before you start coding  Draw a planning sketch or create a sample.
1 Introduction to HTML. 2  W W W – World Wide Web.  HTML – HyperText Markup Language – The Language  of Web Pages on the World Wide Web. HTML is a.
 Definition of HTML Definition of HTML  Tags in HTML Tags in HTML  Creation of HTML document Creation of HTML document  Structure of HTML Structure.
Computer Sciences Department
ULI101: XHTML Basics (Part III) Introduction to XHTML / Continued … Block-Level vs. Inline Elements (tags) Manipulating Text,  , Text Characteristics,,,,,,,,,,,,,,,
CpSc 462/662: Database Management Systems (DBMS) (TEXNH Approach) HTML Basics James Wang.
Chapter 4 Fluency with Information Technology L. Snyder Marking Up With HTML: A Hypertext Markup Language Primer.
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Fluency with Information Technology Third Edition by Lawrence Snyder Chapter.
Chapter 2: The Client Side: HTML CIS 275—Web Application Development for Business I.
HTML Essentials Markup ( Part I ). Why Markup ? Markup gives meaning and structure to your web page Creates a relationship between the elements.
HTML HTML stands for "Hyper Text Mark-up Language“. Technically, HTML is not a programming language, but rather a markup language. Used to create web pages.
HTML (HyperText Markup Language)
ACM 511 HTML Week -1 ACM 511 Course Notes. Books ACM 511 Course Notes.
Chapter 4: Hypertext Markup Language Primer TECH Prof. Jeff Cheng.
Understanding HTML Code
Chapter 2 HTML Basics Key Concepts Copyright © 2013 Terry Ann Morris, Ed.D 1.
McGraw-Hill/Irwin Copyright © 2013 by The McGraw-Hill Companies, Inc. All rights reserved. Extended Learning Module F Building a Web Page with HTML.
1 Introduction to HTML Joshua S. Simon Collective Technologies.
Programming in HTML.  Programming Language  Used to design/create web pages  Hyper Text Markup Language  Markup Language  Series of Markup tags 
 2008 Pearson Education, Inc. All rights reserved Introduction to XHTML.
Just Enough HTML How to Create Basic HTML Documents.
HTML,DHTML & Javascript/Session1/1 of 39 Introduction and Basic Tags Session 1 of Using HTML, DHTML & JavaScript.
HTML: Hyptertext Markup Language Doman’s Sections.
College of Micronesia- FSM Pohnpei State Campus GEORGE S. MANGONON, MBA Chair, Math/Sci Division September 15-25, 2008.
Agenda Block-Level vs. Inline Elements (tags) Manipulating Text,  , Text Characteristics,,,,,,,,,,,,,,, Font Attributes: size, color, face Horizontal.
Ali Alshowaish. What is HTML? HTML stands for Hyper Text Markup Language Specifically created to make World Wide Web pages Web authoring software language.
Introduction to HTML Xiangming Mu 9/23/ Learning Objectives Understand basic HTML tags and their attributes Learn to create a simple HTML page.
CPT 499 Internet Skills for Educators Session Ten Class Notes.
TABLES 1. In this chapter you will learn that tables have many uses in HTML. Objectives: Upon completing this section, you should be able to: 1. Insert.
HTML HyperText Markup Language ©Richard L. Goldman July 15, 2003.
HTML Basics Computers. What is an HTML file? *HTML is a format that tells a computer how to display a web page. The documents themselves are plain text.
CSE 409 – Advanced Internet Technology 1 DISCUSSION OF BASIC HTML TAGS.
©SoftMoore ConsultingSlide 1 Introduction to HTML: Basic Document Structure.
HTML Basics. HTML Coding HTML Hypertext markup language The code used to create web pages.
Spiderman ©Marvel Comics Creating Web Pages (part 1)
WEEK -1 ACM 262 ACM 262 Course Notes. HTML What is HTML? HTML is a language for describing web pages. HTML stands for Hyper Text Markup Language HTML.
HTML HYPER TEXT MARKUP LANGUAGE. INTRODUCTION Normal text” surrounded by bracketed tags that tell browsers how to display web pages Pages end with “.htm”
What is HTML? HTML is a language for describing web pages. HTML stands for Hyper Text Markup Language HTML is not a programming language, it is a markup.
Hypertext Markup Language.  Developed by Tim Berners-Lee in 1990  Stands for HyperText Markup Languange  A format that tells a computer how to display.
1 Introduction to HTML. 2 Definitions  W W W – World Wide Web.  HTML – HyperText Markup Language – The Language of Web Pages on the World Wide Web.
Department of Computer Science, Florida State University CGS 3066: Web Programming and Design Spring
HTML-I Basic HTML Elements. HTML (Hyper Text Markup Language) HTML is a document layout and hyperlink- specification language. i.e. a language used to.
HTML. INDEX Introduction to HTML Creating Web Pages Commands And Tags Web Page.
1 HTML. 2 Full forms WWW – world Wide Web HTTP – Hyper Text Transfer Protocol HTML – Hyper Text Markup Language.
1 Introduction to HTML. 2 Definitions  W W W – World Wide Web.  HTML – HyperText Markup Language – The Language of Web Pages on the World Wide Web.
HTML AN INTRODUCTION TO WEB PAGE PROGRAMMING. INTRODUCTION TO HTML With HTML you can create your own Web site. HTML stands for Hyper Text Markup Language.
Basic Web Publishing M. Scott Gartner 7/15/98.
Introduction to HTML.
Introduction to HTML.
Introduction to HTML.
Tag Basics.
Marking Up with XHTML Tags describe how a web page should look
HNDIT11062 – Web Development
Understand basic HTML and CSS terminology, concepts, and basic operations. Objective 3.01.
Presentation transcript:

Week 7: HTML Basics HNDIT11062 – Web Development

Introduction to HTML

3 Contents Getting Started.. What is HTML? How to create and View an HTML document? Basic HTML Document Format The HTML Basic tags

4  WWW – World Wide Web.  HTML – HyperText Markup Language The language of Web Pages on the World Wide Web. HTML is a text formatting language.  URL – Uniform Resource Locator.  Browser – A software program which is used to show web pages. Definitions

What is HTML? HTML allows you to describe the content of a website. – Headers – Paragraphs – Images – Hyperlinks HTML also allows you to specify relationships between elements and group them.

6  “Normal text” surrounded by bracketed tags that tell browsers how to display web pages  Pages end with “.htm” or “.html”  HTML Editor – A word processor that has been specialized to make the writing of HTML documents more effortless.

Getting Started Make a.html file using a text editor (even Notepad can do it) Open it with your browser. – Usually, your default browser is already configured to open.html files. – So just click the file.

Syntax HTML revolves around tags. Each tag has a special meaning to the browser. Tags are keywords surrounded by brackets <>. They usually come in pairs: opening and closing tags. Examples: – content Will bold the word “content” – more content Defines a paragraph

9  Codes enclosed in brackets  Usually paired E.g. My Web Page  Not case sensitive E.g. = = Tags

10  There are many different programs that you can use to create web documents.  HTML Editors enable users to create documents quickly and easily by pushing a few buttons. Instead of entering all of the HTML codes by hand.  These programs will generate the HTML Source Code for you.  HTML Editors are excellent tools for experienced web developers; however; it is important that you learn and understand the HTML language so that you can edit code and fix “bugs” in your pages.  For this Course, we will focus on using the standard Microsoft Windows text editors, NotePad. Choosing Text Editor

11 NotePad is the standard text editor that come with the Microsoft windows operating system. To start NotePad follow the steps bellow:  Click on the “Start” button located on your Windows task bar.  Click on “Programs” and then click on the directory menu labeled “Accessories”.  Locate the shortcut “NotePad” and click the shortcut once. Starting NotePad

12 In this chapter you will learn to create HTML pages with a standard text editor. Objectives Upon completing this section, you should be able to 1. Choose a Text Editor. 2. Create a Basic Starting Document. 3. Understand and set Document Properties. 4. View Your Results in a Browser. HTML Page Creation & Editing

13 Sri Lanka Institute of Advanced Technological Education This is what is displayed. Creating a Basic Starting Document

14  The HEAD of your document point to above window part.  The TITLE of your document appears in the very top line of the user’s browser. If the user chooses to “Bookmark” your page or save as a “Favorite”; it is the TITLE that is added to the list.  The text in your TITLE should be as descriptive as possible because this is what many search engines, on the internet, use for indexing your site. Creating a Basic Starting Document

15  Document properties are controlled by attributes of the BODY element.  For example,  there are color settings for the background color of the page, the document’s text and different states of links. Setting Document Properties

16 Colors are set using “RGB” color codes, which are, represented as hexadecimal values. Each 2-digit section of the code represents the amount, in sequence, of red, green or blue that forms the color. E.g. A RGB value with 00 as the first two digits has no red in the color. Main Colours Color Codes

17 16 Basic Colors

18 1.WHITE 2.BLACK 3.RED 4.GREEN 5.BLUE 6.MAGENTA 7.CYAN 8.YELLOW 9.AQUAMARINE 10.BAKER’S CHOCOLATE 11.VIOLET 12.BRASS 13.COPPER 14.PINK 15.ORANGE 1.#FFFFFF 2.# #FF #00FF00 5.#0000FF 6.#FF00FF 7.#00FFFF 8.#FFFF00 9.#70DB93 10.#5C #9F5F9F 12.#B5A #B #FF6EC7 15.#FF7F00 Color Codes

19 The BODY element of a web page is an important element in regards to the page’s appearance. This element contains information about the page’s background color, the background image, as well as the text and link colors. E.g. TEXT="#RRGGBB" to change the color of all the text on the page (full page text color) Here are the attributes of the BODY tag to control all the levels:  bgcolor  Background  text The Body Element  link  vlink  alink

20  It is very common to see web pages with their background color set to white or some other colors.  To set your document’s background color, you need to edit the element by adding the BGCOLOR attribute. E.g. Background Color

21 The TEXT attribute is used to control the color of all the normal text in the document. The default color for text is black. E.g. The TEXT attribute would be added as follows: Document's content. In this example the document’s page color is white and the text would be red. TEXT Color

22  The BODY element also gives you ability of setting an image as the document’s background.  An example of a background image’s HTML code is as follows: <BODY BACKGROUND=“hi.gif” BGCOLOR=“#FFFFFF”> Document's content. Using Image Background

23 LINK, VLINK, and ALINK These attributes control the colors of the different link states: 1. LINK – initial appearance – default = Blue. 2. VLINK – visited link – default = Purple. 3. ALINK – active link being clicked– default = Yellow. The Format for setting these attributes is: <BODY BGCOLOR=“#FFFFFF” TEXT=“#FF0000” LINK=“#0000FF” VLINK=“#FF00FF” ALINK=“FFFF00”> Document's content.

24 Headings, Paragraphs, Breaks & Horizontal Rules In this chapter you will add headings to your page, insert paragraphs, add some breaks, and add horizontal rules. Objectives Upon completing this section, you should be able to 1.List and describe the different Heading elements. 2.Use Paragraphs to add text to a document. 3.Insert breaks where necessary. 4.Add a Horizontal Rule.

25 Headings, Inside the BODY element, heading elements H1 through H6 are generally used for major divisions of the document. Headings are permitted to appear in any order, but you will obtain the best results when your documents are displayed in a browser if you follow these guidelines: 1.H1: should be used as the highest level of heading, H2 as the next highest, and so forth. 2.You should not skip heading levels: e.g., an H3 should not appear after an H1, unless there is an H2 between them.

26 Headings, Example Page Heading 1 Heading 2 Heading 3 Heading 4 Heading 5 Heading 6 Heading 1 Heading 2 Heading 3 Heading 4 Heading 5 Heading 6

27 Paragraphs,  Paragraphs allow you to add text to a document in such a way that it will automatically adjust the end of line to suite the window size of the browser in which it is being displayed. Each line of text will stretch the entire length of the window.

28 Paragraphs, Example Page Heading 1 Paragraph 1, …. Heading 2 Paragraph 2, …. Heading 3 Paragraph 3, …. Heading 4 Paragraph 4, …. Heading 5 Paragraph 5, …. Heading 6 Paragraph 6, …. Heading 1 Paragraph 1,…. Heading 2 Paragraph 2,…. Heading 3 Paragraph 3,…. Heading 4 Paragraph 4,…. Heading 5 Paragraph 5,…. Heading 6 Paragraph 6,….

29 Break,  Line breaks allow you to decide where the text will break on a line or continue to the end of the window.  A is an empty Element, meaning that it may contain attributes but it does not contain content.  The element does not have a closing tag.

30 Break, Example Page Heading 1 Paragraph 1, Line 2 Line 3 …. Heading 1 Paragraph 1,…. Line 2 Line 3 ….

31 Horizontal Rule,  The element causes the browser to display a horizontal line (rule) in your document.  does not use a closing tag,.

32 Horizontal Rule, AttributeDescriptionDefault Value SIZE Height of the rule in pixels 2 pixels WIDTH Width of the rule in pixels or percentage of screen width 100% NOSHADE Draw the rule with a flat look instead of a 3D look Not set (3D look) ALIGN Aligns the line (Left, Center, Right) Center COLOR Sets a color for the rule (IE 3.0 or later) Not set

33 Horizontal Rule, Example Page Heading 1 Paragraph 1, Line 2 Line 3 Heading 1 Paragraph 1,…. Line 2 _________________________ __ Line 3

34 Character Formatting In this chapter you will learn how to enhance your page with Bold, Italics, and other character formatting options. Objectives Upon completing this section, you should be able to 1.Change the color and size of your text. 2.Use Common Character Formatting Elements. 3.Align your text. 4.Add special characters. 5.Use other character formatting elements.

35 Bold, Italic and other Character Formatting Elements  Two sizes bigger  The size attribute can be set as an absolute value from 1 to 7 or as a relative value using the “+” or “-” sign. Normal text size is 3 (from -2 to +4).  Bold  Italic  Underline  Color = “#RRGGBB” The COLOR attribute of the FONT element. E.g., this text has color  Preformatted Text enclosed by PRE tags is displayed in a mono-spaced font. Spaces and line breaks are supported without additional elements or special characters.

36 Bold, Italic and other Character Formatting Elements Emphasis Browsers usually display this as italics. STRONG Browsers display this as bold. TELETYPE Text is displayed in a mono- spaced font. A typewriter text, e.g. fixed-width font. Citation represents a document citation (italics). For titles of books, films, etc. Typically displayed in italics. (A Beginner's Guide to HTML)

37 Bold, Italic and other Character Formatting Elements One Size Larger - Normal – One Size Smaller Bold - italics - Underlined - Colored Emphasized - Strong - Tele Type One Size Larger - Normal – One Size Smaller Bold - italics - Underlined - Colored Emphasized - Strong - Tele Type

38 Alignment  Some elements have attributes for alignment (ALIGN) e.g. Headings, Paragraphs and Horizontal Rules.  The Three alignment values are : LEFT, RIGHT, CENTER.  Will center elements.

39 Alignment  Represents a division in the document and can contain most other element type. The alignment attribute of the DIV element is well supported.  Inside a TABLE, alignment can be set for each individual cell.

40 Special Characters & Symbols  These Characters are recognized in HTML as they begin with an ampersand and end with with a semi- colon e.g. &value; The value will either be an entity name or a standard ASCII character number. They are called escape sequences.  The next table represents some of the more commonly used special characters. For a comprehensive listing, visit the W3C’s section on special characters at:

41 Special Characters & Symbols Special Character Entity Name Special Character Entity Name Ampersand & & Greater-than sign > > Asterisk∗ ∗∗ Less-than sign < < Cent sign ¢ ¢ Non-breaking space Copyright © © Quotation mark " " Fraction one qtr ¼ ¼ Registration mark ® ® Fraction one half ½ ½ Trademark sign ™ ™

42 Additional escape sequences support accented characters, such as: ö – a lowercase o with an umlaut: ö ñ – a lowercase n with a tilde: ñ È – an uppercase E with a grave accent: È NOTE: Unlike the rest of HTML, the escape sequences are case sensitive. You cannot, for instance, use &LT; instead of <. Special Characters & Symbols

43 Additional Character Formatting Elements  strike-through text DEL is used for STRIKE at the latest browsers  places text in a big font  places text in a small font  places text in subscript position  places text in superscript style position

44 Example strike-through text places text in a big font places text in a small font places text in subscript position Normal places text in superscript style position