Web Programming– UFCFB Lecture 5

Slides:



Advertisements
Similar presentations
HTML popo.
Advertisements

Internet Services and Web Authoring (CSET 226) Lecture # 5 HyperText Markup Language (HTML) 1.
HTML: HyperText Markup Language Hello World Welcome to the world!
HTML popo.
INTRODUCTION TO HYPERTEXT MARKUP LANGUAGE 1. Outline  Introduction  Markup Languages  Editing HTML  Common Tags  Headers  Text Styling  Linking.
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.
 2003 Prentice Hall, Inc. All rights reserved. Chapter 4 - Introduction to XHTML: Part 1 Outline 4.1 Introduction 4.2 Editing XHTML 4.3 First XHTML Example.
 2008 Pearson Education, Inc. All rights reserved. 1 Introduction to HTML.
 2004 Prentice Hall, Inc. All rights reserved. Introduction to XHTML: Part 1.
Introduction to HTML II Shih-Heng Chin. Preface Structure of a HTML File Elements used frequently Tables.
Creating a Web Page HyperText Markup Language. HTML Documents  Created using any text editor  Notepad  Vi, Pico, or Emacs  If using word-processor,
 2003 Prentice Hall, Inc. All rights reserved. Chapter 4 - Introduction to XHTML: Part 1 Outline 4.1 Introduction 4.2 Editing XHTML 4.3 First XHTML Example.
CS105 Introduction to Computer Concepts HTML
 2008 Pearson Education, Inc. All rights reserved Introduction to XHTML.
 2002 Prentice Hall, Inc. All rights reserved.2 Chapter 2 — Introduction to HyperText Markup Language 4: Part I Outline 2.1Introduction 2.2Markup Languages.
1 CSC 121 Computers and Scientific Thinking David Reed Creighton University HTML and Web Pages.
Introduction to HTML. What is a HTML File?  HTML stands for Hyper Text Markup Language  An HTML file is a text file containing small markup tags  The.
 2008 Pearson Education, Inc. All rights reserved Introduction to XHTML.
CS105 INTRODUCTION TO COMPUTER CONCEPTS HTML Instructor: Cuong (Charlie) Pham.
Introduction to HTML Wah Yan College (Hong Kong) Mr. Li C.P.
HTML: Hyptertext Markup Language Doman’s Sections.
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.
HTML Basics. HTML Coding HTML Hypertext markup language The code used to create web pages.
HTML CS 105. Page Structure HTML elements control the details of how a page gets displayed. Every HTML document has the following basic structure: … …
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.
Department of Computer Science, Florida State University CGS 3066: Web Programming and Design Spring
1999, COMPUTER SCIENCE, BUU Introduction to HTML Seree Chinodom
HTML. INDEX Introduction to HTML Creating Web Pages Commands And Tags Web Page.
Chapter 4 HTML Tags. HTML is written in something called tags. Tags come in pairs, an opening one and a closing one. The first pair of tags we'll write.
HTML And the Internet. HTML and the Internet ► HTML: HyperText Markup Language  Language in which all pages on the web are written  Not Really a Programming.
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.
Introduction to HTML.
HTML Basics.
CGS 3066: Lecture 2 Web Development and HTML5
Web Development Part 1.
BHS Web Design Mr. Campbell
What is HTML? Acronym for: HyperText Markup Language
LAB Work 01 MBA 61062: E-Commerce
Marking Up with XHTML Tags describe how a web page should look
Semester - Review.
HTML 2.
Introduction to basic HTML
Elements of HTML Web Design – Sec 3-2
HTML: HyperText Markup Language
Elements of HTML Web Design – Sec 3-2
Text Elements.
Chapter 1: Introduction to XHTML (part 1)
Introduction to XHTML.
Elements of HTML Web Design – Sec 3-2
Chapter 4 - Introduction to XHTML: Part 1
Elements and Attributes
COMPUTING FUNDAMENTALS
HTML (HyperText Markup Language)
Computers and Scientific Thinking David Reed, Creighton University
Marking Up with XHTML Tags describe how a web page should look
Marking Up with XHTML Tags describe how a web page should look
CGS 3066: Lecture 2 Web Development and HTML5
HTML HTML is a language for describing web pages.
1 Introduction to XHTML.
Introduction to HTML- Basics
Html.
Introduction to HTML.
Marking Up with XHTML Tags describe how a web page should look
Marking Up with XHTML Tags describe how a web page should look
Johan Ng and Muhammad Hazzry
AN INTRODUCTION BY FAITH BRENNER
Marking Up with XHTML Tags describe how a web page should look
CGS 3066: Web Programming and Design Fall 2019
Presentation transcript:

Web Programming– UFCFB3-30-1 Lecture 5 Instructor : Mazhar H Malik Email : mazhar@gcet.edu.om Global College of Engineering and Technology

Introductions to HTML LO 2,5,6 Lecture 5 Introductions to HTML LO 2,5,6 9/13/2018 Lecture 5

In this lecture… HTML Heading, Paragraph Text formatting Image Marquee Create a link Comments 9/13/2018 Lecture 5

HTML Hypertext Markup Language The language used to create web documents Current version is HTML 4.01 All page elements are identified by special tags The tags give the browser instructions on how to display the content the tags themselves don’t display 9/13/2018 Lecture 5

HTML Tags are enclosed in < and > Example: <title> tag Tags are nested Tags may be UPPERCASE or lowercase. This paper uses lowercase as the standard Future iterations of HTML will require lowercase, so it is a good habit to start with 9/13/2018 Lecture 5

HTML Example <html> <head> <title>Title of page</title> </head> <body> <p>This is my first page.<p> </body> </html> 9/13/2018 Lecture 5

HTML page structure html head body title p b i ….. 9/13/2018 Lecture 5

HTML page structure <html> </html> Defines the text file as being in HTML format. This is found on the beginning and end of each web page. <head> </head> The heading area of a the page. <title> </title> Defines the title displayed at the title bar of the browser window. <body> </body> Found after the <head> tag and is used to define the area of the file which formats the way the web page is seen. 9/13/2018 Lecture 5

Pairs and stand-alone Most tags come in pairs Start tag and End tag E.g. <b> and </b> There are some standalone tags, e.g. <br> which inserts a line break <hr> which inserts a horizontal rule (i.e. a line) 9/13/2018 Lecture 5

Some tags have attributes These extend or modify a tag’s actions (note American spelling) Example: <body bgcolor=“#000000”> …</body> The tag is the body tag; this is the area within the browser window The attribute is bgcolor (background color), and has the value “#000000”, which is black 9/13/2018 Lecture 5

Background attribute The background attribute specifies a background-image for an HTML page. The value of this attribute is the URL of the image you want to use. If the image is smaller than the browser window, the image will repeat itself until it fills the entire browser window. Large image file increase the loading time. <body background="clouds.gif"> 9/13/2018 Lecture 5

Heading Headings are defined with the <h1> to <h6> tags. <h1> defines the largest heading. <h6> defines the smallest heading. HTML automatically adds an extra blank line before and after a heading 9/13/2018 Lecture 5

Paragraph Paragraphs are defined with the <p> tag. HTML automatically adds an extra blank line before and after a paragraph. 9/13/2018 Lecture 5

Heading and Paragraph Example <html> <body> <h1>This is a heading</h1> <h2>This is a heading</h2> <h3>This is a heading</h3> <h4>This is a heading</h4> <h5>This is a heading</h5> <h6>This is a heading</h6> <p> this is default paragraph text</p> </body> </html> 9/13/2018 Lecture 5

Line Breaks The <br> tag is used when you want to end a line, but don't want to start a new paragraph. The <br> tag forces a line break wherever you place it. The <br> tag is an empty tag. It has no closing tag. Example <p>This <br> is a para<br>graph with line break</p> 9/13/2018 Lecture 5

Horizontal Rule The <hr>tag defines a horizontal rule. The <br> and <hr> tag is an empty tag. It has no closing tag. Example <p>Good morning <hr> this is under the line</p> 9/13/2018 Lecture 5

Text formatting using HTML HTML use different tags for text formatting <b> bold text <i> italic text <big> big text <small> small text <sub>subscript text <sup>superscript text 9/13/2018 Lecture 5

Text formatting Example <html><body> <p> this is default text</p> <b>This text is bold</b><br> <i>This text is italic</i><br> <big>This text is big</big><br> <small>This text is small</small><br> This text contains<sub>subscript</sub><br> This text contains<sup>superscript</sup> </body></html> 9/13/2018 Lecture 5

Image HTML use <img> tag to insert an image. src attribute locate the (source) file of the image. alt attribute display a text message if the browser is unable to show the image. 9/13/2018 Lecture 5

Image example <html> <body> <p>This is Oman's flag </p> <img src="oman.gif“ alt=“oman flag picture" > </body> </html> 9/13/2018 Lecture 5

Marquee is a moving text in you web site. Marquee make your site more attractive. The following marquee is moving to left . <marquee width=200 height=50 direction=left bgcolor=yellow> Hi There </marquee> 9/13/2018 Lecture 5

Marquee The following marquee is moving to right with a delay of 400 ms. <marquee width=200 height=50 direction=right behavior=alternate scrolldelay=400 bgcolor=red> this is marquee </marquee> 9/13/2018 Lecture 5

Create a link HTML uses the <a> (anchor) tag to create a link to another document. An anchor can point to any resource on the Web: an HTML page, an image, a sound file, a movie, etc. 9/13/2018 Lecture 5

The Anchor Tag and the Href Attribute The syntax of creating an anchor:  <a href="url">Text to be displayed</a> the href attribute is used to address the document to link to, and the words between the open and close of the anchor tag will be displayed as a hyperlink. 9/13/2018 Lecture 5

Link Example <html> <body> <p> If you want to check you hotmail <a href="http://www.msn.com/">click here</a></p> </body> </html> 9/13/2018 Lecture 5

Comments in HTML The comment tag is used to insert a comment in the HTML source code. A comment will be ignored by the browser. You can use comments to explain your code, which can help you when you edit the source code at a later date. Example <!-- This is a comment --> 9/13/2018 Lecture 5

Ordered List An ordered list is also a list of items. The list items are marked with numbers. An ordered list starts with the <ol> tag. Each list item starts with the <li> tag. <ol> <li>Coffee</li> <li>Milk</li> </ol> 9/13/2018 Lecture 5

Unordered List An unordered list is a list of items. The list items are marked with bullets (typically small black circles). An unordered list starts with the <ul> tag. Each list item starts with the <li> tag. <ul> <li>Coffee</li> <li>Milk</li> </ul> 9/13/2018 Lecture 5

Tables Tables are defined with the <table> tag. A table is divided into rows (with the <tr> tag), and each row is divided into data cells (with the <td> tag). The letters td stands for "table data," which is the content of a data cell. A data cell can contain text, images, lists, paragraphs, forms, horizontal rules, tables, etc. 9/13/2018 Lecture 5

Tables Example <table border="1"> <tr> <td>row 1, cell 1</td> <td>row 1, cell 2</td> </tr> <td>row 2, cell 1</td> <td>row 2, cell 2</td> </table> 9/13/2018 Lecture 5

Create Page Template To build effective page templates, you must be familiar with the HTML table elements and attributes The <table> element contains the table information, which consists of table row elements <tr>, and individual table data cells <td>. These are the three elements you will use most frequently when you are building tables. 9/13/2018 Lecture 5

Page Thumbnail 9/13/2018 Lecture 5

9/13/2018 Lecture 5

Same Page Template 9/13/2018 Lecture 5

Summary HTML use different (elements) tags to format web pages. Tags can have attributes. Attributes can provide additional information about the HTML elements on your page. HTML supports images, links. Also support tables, lists. 9/13/2018 Lecture 5