Web Design & Development

Slides:



Advertisements
Similar presentations
Table, List, Blocks, Inline Style
Advertisements

Copyright © 2004 ProsoftTraining, All Rights Reserved. Lesson 6: HTML Tables.
HTML: HyperText Markup Language Hello World Welcome to the world!
HTML popo.
CS134 Web Design & Development Attributes, Lists, Tables, Links, and Images Mehmud Abliz.
Chapter 4 – Intermediate HTML 4 Outline 4.1 Unordered Lists 4.2 Nested and Ordered Lists 4.3 Basic HTML Tables 4.4 Intermediate HTML Tables and Formatting.
Introduction to Web Site Development Steven Emory Department of Computer Science California State University, Los Angeles Lecture 4: Tables and Frames.
Unit 2, cont. September 14 HTML,Validating your pages, Publishing your site.
 2008 Pearson Education, Inc. All rights reserved. 1 Introduction to HTML.
Introduction to HTML II Shih-Heng Chin. Preface Structure of a HTML File Elements used frequently Tables.
HTML. Goals How to use the Komodo editor HTML coding and testing – List and Images – Tables and Links – At least 2 pages and navigation –
CS105 Introduction to Computer Concepts HTML
Dr. Nuha El-KhaliliInternet Programming ( ) HTML Hyper Text Markup Language The language of web pages Maintained by the W3C
CS134 Web Design & Development Creating a Basic Web Page Exerted from Mehmud Abliz slides.
Chapter 2 HTML Basics Key Concepts Copyright © 2013 Terry Ann Morris, Ed.D 1.
HTML Hyper-Text Markup Language or tags. HTML is a “tag” language Open and close tags Tags identified with angle brackets Basic format content (shorthand.
>> Introduction to HTML: Tables. HTML is used to give websites structure 5 Basic Tags Element = Start-Tag+Content+End-Tag Heading Tags [h1-h6] Paragraph.
CS105 INTRODUCTION TO COMPUTER CONCEPTS HTML Instructor: Cuong (Charlie) Pham.
 2008 Pearson Education, Inc. All rights reserved Introduction to XHTML.
XHTML 1.1  Derived from Standard Generalized Markup Language (SGML) of ISO  XHTML concerned primary with content rather than presentation and style 
4 Chapter Four Introduction to HTML. 4 Chapter Objectives Learn basic HTML commands Discover how to display graphic image objects in Web pages Create.
Computer Science 101 Lists and Tables. Lists Unordered lists - use a bullet Ordered lists - use a number, Roman numeral, or letter.
CIS234A Lecture 8 Instructor Greg D’Andrea. Review Text Table contains only text, evenly spaced on the Web page in rows and columns uses only standard.
XP Review 1 New Perspectives on JavaScript, Comprehensive1 Introducing HTML and XHTML Creating Web Pages with HTML.
Department of Computer Science, Florida State University CGS 3066: Web Programming and Design Spring
CS134 Web Design & Development Attributes, Lists, Tables, Links, and Images Mehmud Abliz.
`. Lecture Overview HTML Body Elements Linking techniques HyperText references Linking images Linking to locations on a page Linking to a fragment on.
Department of Computer Science, Florida State University CGS 3066: Web Programming and Design Spring
1999, COMPUTER SCIENCE, BUU Introduction to HTML Seree Chinodom
INT222 – Internet Fundamentals
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.
Tutorial 1 – Creating Web Pages With HTML
HTML Basics.
CGS 3066: Lecture 2 Web Development and HTML5
LAB Work 01 MBA 61062: E-Commerce
Marking Up with XHTML Tags describe how a web page should look
Organizing Content with Lists and Tables
Web Development & Design Foundations with HTML5
Yourfriendmanoj.wordpress.com Fb/yourfriendmanoj
Working with Tables: Module A: Table Basics
Elements of HTML Web Design – Sec 3-2
HTML: HyperText Markup Language
Elements of HTML Web Design – Sec 3-2
Web Development & Design Foundations with HTML5 8th Edition
HTML Formatting.
CGS 3066: Web Programming and Design Spring 2016
Programming the Web using XHTML and JavaScript
Chapter 1: Introduction to XHTML (part 1)
HTML Lists CS 1150 Fall 2016.
The Web Warrior Guide to Web Design Technologies
Elements of HTML Web Design – Sec 3-2
COMPUTING FUNDAMENTALS
Using HTML Tables SWBAT: - create tables using HTML
Web Design and Development
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
Introduction to XHTML Cont:.
HTML Lists CS 1150 Spring 2017.
Web Development & Design Foundations with H T M L 5
Introduction to HTML.
Web Development & Design Foundations with HTML5
Chapter 4: Marking Up With HTML: A Hypertext Markup Language Primer
Marking Up with XHTML Tags describe how a web page should look
Marking Up with XHTML Tags describe how a web page should look
Web Client Side Technologies Raneem Qaddoura
Web Development & Design Foundations with HTML5
Marking Up with XHTML Tags describe how a web page should look
CGS 3066: Web Programming and Design Fall 2019
Presentation transcript:

Web Design & Development Attributes, Lists, Tables, Links, and Images

Basic syntax for xhtml tags and attributes An attribute is a special code that can enhance or modify a tag. They are generally located in the starting tag after the tag name. Basic syntax for xhtml tags and attributes <tag attribute="value">   </tag> All tags must be lower case all values of attributes need to be surrounded by quotes block-level elements generally start in a new line; something that doesn't apply to inline-level elements.

id class style title unique identifier for elements Common Attributes id unique identifier for elements class the class of the element, used to specify similar attributes for dissimilar elements by putting them in the same class style an inline style definition title a text to display in a tool tip block-level elements generally start in a new line; something that doesn't apply to inline-level elements.

Examples 1 Example 2 Assuming style sheet contains Common Attributes Examples 1 <p id=“firstParag” class=“indent” title=“This paragraph introduces html attributes”> Assuming style sheet contains .indent { margin-right: 5%; margin-left: 5%;} Example 2 <p id=“firstParag” style=“margin-right: 5%; margin-left: 5%;” title=“This paragraph introduces html attributes”> block-level elements generally start in a new line; something that doesn't apply to inline-level elements.

lang dir accesskey tabindex Common Attributes lang sets the language code; “en”: English, “fr”: French, “es”: Spanish, “de”: German etc. dir sets the text direction, left to right or right to left <p lang=“fr” dir=“ltr”>bonjour!</p> accesskey assigns an access key to an element. An access key is a single character from the document character set. tabindex Sets the tab order of an element block-level elements generally start in a new line; something that doesn't apply to inline-level elements.

Deprecated Attributes In order to separate structure from presentation many HTML attributes/tags used for presentation were deprecated, starting from HTML version 4 Some deprecated attributes font, <font size=“5” color=“red”>Text</font> align, <p align=“center”>Centered text</p> bgcolor, width, height, etc.

Ordered lists & Unordered lists <ol> for ordered <ul> for unordered <li> for each item inside the list Browser inserts a blank line before & after the list (block-level element) Example <ol> <li>Item 1</li> <li>Item 2</li> <li>Item3</li> </ol>

Nested lists Lists <ul> <li>Top Level, Item 1</li> <li>Sublevel 1, Item 1 <li>Sublevel 2, Item 1</li> <li>Sublevel 2, Item 2</li> </ul> </li> <li>Sublevel 1, Item 2</li> <li>Top Level, Item 3</li>

Customizing List Display List numbers or marks can be customized “type” attribute Example <ul type=“square”> <ol type=“A”> <ol type=“a”> <ol type=“I”> <ol type=“i”> “type” attribute is not allowed in XHTML 1.0 Strict, so use style sheets instead

Definition Lists <dl> for list element; <dt> for “definition terms”; <dd> for “definition data” Example <dl> <dt><strong>CPU</strong></dt> <dd>Central Processing Unit</dd> <dt><strong>ALU</strong></dt> <dd>Arithmetic Logic Unit</dd> <dt><strong>GHz</strong></dt> <dd>Gigahertz</dd> </dl>

Tables used not only for displaying data in tabular format Tables <table> Tables used not only for displaying data in tabular format A table (<table>) in HTML Consists of rows (<tr>) Each row consists of rectangular boxes called cells (<td>) <table> <tr><td>R1,Cell1</td><td>R1,Cell2</td></tr> <tr><td>R2,Cell1</td><td>R2,Cell2</td></tr> </table>

Tables By default Text in each cell is automatically aligned to the left All the cells in a column have the same width Width of the column is determined by the cell with the most text in it <th> for “table header” <tr> <th>Header1</th> <th>Header2</th> </tr>

Other attributes of <table> Tables Other attributes of <table> align, cellpadding, cellspacing, colspan Yet XHTML 1.0 Strict don’t allow this attributes, so use stylesheet instead Other tags <caption> <colgroup> <thead>, <tfoot>, <tbody>

The true power of WWW comes with hyperlinks Surfer click on a specially marked word or image on a web page and automatically be jumped to another web page or another place in the same web page. Another web page – External link Another place – Internal link Use <a> (anchor) tag to create a link

Create a link to CS web page Links External Links <a href=“SomeURL”>Text/image</a> Create a link to CS web page <a href=“http://www.cs.pitt.edu/”>CS Department at Pitt</a> Be careful about the quotation mark Internal Links Create a place/anchor <a id=“SomeLabel”></a> or <a id=“SomeLabel” name=“SomeLabel”/></a> Link to the anchor <a href=“#SomeLabel”>Go to some place</a>

Combining External and Internal Links <a href=“SomeURL#SomeLabel>Link Text</a>

Insert an image using <img> tag Images <img> Insert an image using <img> tag <img src=“URL of the image file” /> Image can an image on a remote machine on the Internet, or an image in your local machine. Examples, <img src="http://www.cs.pitt.edu/~mehmud/gallery/nature/images/Desert_and_Blue_Sky.jpg"/> <img src="../images/Lake_Karakul.jpg" />

Alternative Text for images Example width & height attributes <img src=“Image URL” alt=“Alternative Text” /> Example <img src="../images/Lake_Karakul.jpg" alt="Lake Karakul"/> width & height attributes <img src="../images/Lake_Karakul.jpg" alt="Lake Karakul" width="257" height="161" /> Use style sheet instead of attributes, even though XHTML 1.0 Strict supports these two attributes