HTML5 and CSS3 Illustrated Unit F: Inserting and Working with Images.

Slides:



Advertisements
Similar presentations
Introduction to Web Design Lecture number:. Todays Aim: Introduction to Web-designing and how its done. Modelling websites in HTML.
Advertisements

Working with Images and HTML
Use Tables for Layout Control Day 7. You will learn to: Understand Tables Create a Simple Table Modify Your Tables Appearance Create Page Layouts with.
Chapter 3 – Web Design Tables & Page Layout
Iframes & Images Using HTML.
1 Cascading Style Sheets Continued Different kinds of selectors in a style sheet –Simple- Pseudo-Class –Contextual- Pseudo-Element –Class Image Styles.
Web Development & Design Foundations with XHTML Chapter 4 Key Concepts.
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 4 Key Concepts 1 Copyright © Terry Felke-Morris.
Adobe Flash CS4 – Illustrated Unit E: Optimizing and Publishing a Movie.
Introduction to HTML Lists, Images, and Links. Before We Begin Save another file in Notepad Save another file in Notepad Open your HTML, then do File>Save.
Cascading Style Sheets Controlling the Display Of Web Content.
Cascading Style Sheets Controlling the Display Of Web Content.
Using HTML Tables.
Chapter 4 Adding Images. Inserting and Aligning Images Using CSS When you choose graphics to add to a web page, it’s important to use graphic files in.
4.01 Cascading Style Sheets
Working with Cascading Style Sheets. 2 Objectives Introducing Cascading Style Sheets Using Inline Styles Using Embedded Styles Using an External Style.
Chapter 5 Web Graphics Styling Basics Key Concepts Copyright © 2013 Terry Ann Morris, Ed.D 1.
Chapter 3 Adding Images in HTML. Agenda Understanding Web Page Images Prepare Your Images for the Web Insert an Image Specify an Image Size Add Alternative.
1 The Structure of a Web Table beginning of the table structure first row of three in the table end of the table structure table cells You do not need.
Adding Images & Working with Images Unit 2. TITLE CORNELL NOTES TOPIC: NOTES: Name: Date:08/10/2009 Period : Summary: To display Art To display Photographs.
Working with Cascading Style Sheets. Introducing Cascading Style Sheets Style sheets are files or forms that describe the layout and appearance of a document.
XP Tutorial 7New Perspectives on Creating Web Pages with HTML, XHTML, and XML 1 Working with Cascading Style Sheets Creating a Style for Online Scrapbooks.
Web Graphics Image File Formats Image optimization Accessibility issues Using images and colors on the web.
Chapter 3 Dreamweaver: Part I The Web Warrior Guide to Web Design Technologies.
Chapter 4 Adding Images. Chapter 4 Lessons Introduction 1.Insert and align images 2.Enhance an image and use alternate text 3.Insert a background image.
Building the User Interface by Using HTML5: Text, Graphics, and Media Lesson 2.
HTML Boot Camp: Rules and Images
.  Entertain  Inform  Educate  Blogs  Sell  Date  Gamble  Religion.
WEB DESIGN USING DREAMWEAVER. The World Wide Web –A Web site is a group of related files organized around a common topic –A Web page is a single file.
XHTML Images. Images are important Purpose: to enhance your web site. Add only when they complement or add additional impact to your message.
1 Mastering the Internet and HTML Images and Image Tags.
Images Inserting an image on a web page. chcslonline.org2 ITEMS REQUIRED Go to the course download page on the course website and download the 3 images.
Images (1) Three most popular formats – Graphics Interchange Format (GIF) – Joint Photographic Experts Group (JPEG) – Portable Network Graphics (PNG) –
Images in HTML PowerPoint How images are used in HTML.
Section 4.1 Format HTML tags Identify HTML guidelines Section 4.2 Organize Web site files and folder Use a text editor Use HTML tags and attributes Create.
XP Mohammad Moizuddin Creating Web Pages with HTML Tutorial 1 1 New Perspectives on Creating Web Pages With HTML Tutorial 1: Developing a Basic Web Page.
 This presentation introduces the following: › 3 types of CSS › CSS syntax › CSS comments › CSS and color › The box model.
Chapter 5 Web Graphics Styling Basics Key Concepts Copyright © 2013 Terry Ann Morris, Ed.D 1.
CHAPTER 4 LINKS Creating links between pages Linking to other sites links.
Designing a Web Page with Tables. A text table: contains only text, evenly spaced on the Web page in rows and columns uses only standard word processing.
Chapter 4 BIE1313/BPROG1203 | Web design Prepared by Mohamed Abdulkarim / Mike Ng Ah Ngan.
Adobe Dreamweaver CS3 Revealed CHAPTER THREE: WORKING WITH TEXT AND IMAGES.
Adding Images Learning Web Design: Chapter 7. Using an Image Images have many purposed on a Web site Used as a static image To add illustration: ex. A.
4 Chapter Four Introduction to HTML. 4 Chapter Objectives Learn basic HTML commands Discover how to display graphic image objects in Web pages Create.
Copyright (c) 2004 Prentice-Hall. All rights reserved. 1 Committed to Shaping the Next Generation of IT Experts. Adding Graphical Elements Essentials for.
Macromedia Dreamweaver 8 Revealed AND GRAPHICS WORKING WITH TEXT.
The Web Wizard’s Guide to HTML Chapter Three Colors, Patterns, and Inline Graphics.
© 2011 Delmar, Cengage Learning Chapter 4 Adding Images.
CNIT 132 – Week 4 Cascading Style Sheets. Introducing Cascading Style Sheets Style sheets are files or forms that describe the layout and appearance of.
Web Design (12) CSS Introduction. Cascading Style Sheets - Defined CSS is the W3C standard for defining the presentation of documents written in HTML.
HTML IMAGES. CONTENTS IMG Tag Alt Attribute Setting Width and Height Of An Image Summary Exercise.
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: … …
Lesson 6 - Images. Let’s talk about resolutionLet’s talk about resolution.
Basic HTML Programming Technology Education Ellsworth Community Middle School Communication Systems.
REEM ALMOTIRI Information Technology Department Majmaah University.
NASRULLAHIBA.  It is time to take your web designing skills to the next level with Cascading Style Sheets (CSS). They are a way to control the look and.
XP Tutorial 7New Perspectives on HTML and XHTML, Comprehensive 1 Working with Cascading Style Sheets Creating a Style for Online Scrapbooks Tutorial 7.
Unit G - Images. Unit G - Images The great questions of life? How does an airplane stay up? Where does the tooth fairy get her money? Why is the sky.
Laying out Elements with CSS
4.01 Cascading Style Sheets
Inserting and Working with Images
HTML Images CS 1150 Spring 2017.
Chapter 3 Images.
Unit G - Images. Unit G - Images The great questions of life? How does an airplane stay up? Where does the tooth fairy get her money? Why is the sky.
DREAMWEAVER MX 2004 Chapter 3 Working with Tables
Cascading Style Sheets™ (CSS)
HTML Images CS 1150 Fall 2016.
4.01 Cascading Style Sheets
Presentation transcript:

HTML5 and CSS3 Illustrated Unit F: Inserting and Working with Images

Objectives Evaluate image file types Insert images Align images Control page flow HTML 5 and CSS 3 – Illustrated Complete 2

Objectives Insert a background image Associate images with related text Use images as links Insert a favicon HTML 5 and CSS 3 – Illustrated Complete 3

Image File Types Images can be added to a Web page by linking to a separate file Different image file types:   Bitmap image: represented as grid of dots of specified colors e.g., JPG, GIF, and PNG   Vector graphic: encoded as geometric shapes e.g., SVG (scalable vector graphic) HTML 5 and CSS 3 – Illustrated Complete 4

Image File Types Common file formats:   JPG: optimized for many colors photographs   GIF: optimized for areas with defined borders, few colors Line drawings Supports transparent pixels   PNG: allows user to specify opacity level for areas   SVG: no decrease in quality when scaled HTML 5 and CSS 3 – Illustrated Complete 5

Image File Types Bitmap should be created and formatted for use on Web   Created and displayed at set resolution and size Resolution: how close dots should be in the output   Measured in dots per inch (dpi) or pixels per inch (ppi)   High resolution = more detail, large file size = longer download time HTML 5 and CSS 3 – Illustrated Complete 6

Image File Types Size: length and width of image   Pixels: individual dots that make up the image   Bitmaps display optimally at native size   Scaling affects download time and image quality HTML 5 and CSS 3 – Illustrated Complete 7

Inserting Images element: used to add an image to HTML document   One-sided element   Must include two attributes: src: path and filename to the image file alt: text to display if image is unavailable   Inline element by default Within text, aligned to text baseline Can be wrapped in block element for alignment purposes HTML 5 and CSS 3 – Illustrated Complete 8

Inserting Images Width and height attributes:   Not required   Can be used to specify the native dimensions of an image   Always in pixels, no need to specify units HTML 5 and CSS 3 – Illustrated Complete 9

Inserting Images HTML 5 and CSS 3 – Illustrated Complete 10

Aligning Images figure element: used to mark images that add information to a Web page   Semantic element   Enables user agent to link figure element contents to another location without affecting information conveyed CSS float attribute: enables Web page elements to flow around figure   Left and right values align figure HTML 5 and CSS 3 – Illustrated Complete 11

Aligning Images Use of CSS float property and resulting Web page HTML 5 and CSS 3 – Illustrated Complete 12

Controlling Page Flow CSS float property not always sufficient for desired page layout CSS clear property: prevents floated elements from being displayed to the side of another element   Allows more precise control of Web page flow HTML 5 and CSS 3 – Illustrated Complete 13

Controlling Page Flow Use of CSS clear property and resulting Web page HTML 5 and CSS 3 – Illustrated Complete 14

Inserting Background Image Background of Web page or element   Specify path and filename as value for background property in CSS   Important to maintain contrast between background and text   Specify background color also in case image not available or not supported Tiling: displaying images repeatedly   Used by user agents to fill screen space   Be sure it’s not noticeable! HTML 5 and CSS 3 – Illustrated Complete 15

Syntax of background property:   background: url(“url goes here”)   background: color Goes in body property if affecting entire page When property-value pairs conflict, the one that occurs later in the rule takes precedence HTML 5 and CSS 3 – Illustrated Complete 16 Inserting Background Image

HTML 5 and CSS 3 – Illustrated Complete 17 Code for background color & image Inserting Background Image

Associating Images with Related Text figcaption element: marks text as a caption for associated image   Nested in figure element for the image   Provides context, explanation or credit to img title attribute: specifies add’l img info   Browsers display as floating text during mouse-over When not specified, some browsers display alt text HTML 5 and CSS 3 – Illustrated Complete 18

Associating Images with Related Text HTML 5 and CSS 3 – Illustrated Complete 19 Figure caption code and result

Using Images as Links Images can be used as links   Enclose img element within an a element Browsers typically add border around linked image to display link state   Use CSS border property to remove the border   Use pseudo-classes to modify link state colors of the image HTML 5 and CSS 3 – Illustrated Complete 20

Inserting a Favicon Favicon: icon associated with Web page in the address bar and on bookmarks/favorites lists   16 x 16 pixels   Saved in.ico format To specify for all pages of Web site, place in root folder for the site Use link element HTML 5 and CSS 3 – Illustrated Complete 21

Inserting a Favicon HTML 5 and CSS 3 – Illustrated Complete 22 Note: Favicon will not display in IE if page is only in a local folder :(

Summary Bitmap images: represented as grid of dots of specified colors Vector graphic: encoded as geometric shapes Bitmaps should be created and formatted for use on the Web Quality of image is determined by resolution and size HTML 5 and CSS 3 – Illustrated Complete 23

Summary (continued) Use one sided img element to insert image   Must include src and alt attributes figure element: used to mark images that add information to Web page CSS float and clear properties: used to control page flow HTML 5 and CSS 3 – Illustrated Complete 24

Summary (continued) Image can be used as page background   User agents tile image if necessary figcaption element: can be used to include figure caption Images can be used as links when enclosed in an a element Favicon: icon associated with Web page in address bar HTML 5 and CSS 3 – Illustrated Complete 25