Académique Documents
Professionnel Documents
Culture Documents
Chapters 4, 5 and 11 from Web development and Design Foundations with XHTML
Learning Outcomes
In this chapter, you will learn to:
Decide when to use graphics and what graphics are appropriate Apply the image element to add graphics to Web pages Configure images as backgrounds on Web page elements Configure images as hyperlinks Know about Helper Applications and Plug-ins
Audio file types & Adding sound to a web page Video file types & Adding video to a web page
Chapter 4
WEB GRAPHICS
Types of Graphics
Graphic types commonly used on Web pages:
GIF (Graphics Interchange Format)
Best used for line art and logos Can be animated
src Attribute
File name of the graphic
alt Attribute
Configures alternate text content (description)
height Attribute
Height of the graphic in pixels
width Attribute
Width of the graphic in pixels
Image Links
To create an image link use an anchor element to contain an image element
their own folder Code the path to the file in the src atttribute
Chapter 11
MULTIMEDIA
10
11
12
13
<object data= "soundloop.mp3" height="50" width= "50 type="audio/mpeg" title= "Music Sound Loop" > <param name= src" value= "soundloop.mp3" /> </object>
14
15
<object data=lighthouse.mov" height=260" width=340" type="video/quicktime" title=Door County Lighthouse Tour" > <param name="src" value=lighthouse.mov" /> <param name="controller" value="true" /> <param name="autoplay" value="false" /> </object>
16
Adding Flash to a Web Page <object> & <param <param /> tags
<object object attributes go here. <param name="movie" value attribute goes here /> <param name="quality" value attribute goes here /> <param name="bgcolor" value attribute goes here /> a brief description of the Flash media can go here along with a link to alternate text content if appropriate </object>
17
18
Design Principles
Repetition
Repeat visual elements throughout design
Contrast
Add visual excitement and draw attention
Proximity
Group related items
Alignment
Align elements to create visual unity
20
22
Watch the load time of your pages Try to limit web page document and associated media to under 60K on the home page
23
24
Everyone:
Good contrast between background and text Easy to read Avoid animation if it makes the page load too slowly
Accessibility Tip: Many individuals are unable to distinguish between certain colors.
See http://www.vischeck.com/showme.shtml
25
Design to look best in one browser and degrade gracefully (look OK) in others
26
28
Use strong contrast between text & background Use columns instead of wide areas of horizontal text
29
30
Use the alt attribute to supply descriptive alternate text Be sure your message gets across even if images are not displayed.
If using images for navigation provide plain text links at the bottom of the page.
Use animation only if it makes the page more effective and provide a text description.
31
Use anti-aliased text in images Use only necessary images Reuse images Goal: image file size should be as small as possible
32
33
Summary
This chapter introduced the use of graphics & multimedia on Web pages and the best practices of web design. The number one reason for visitors to leave web pages is too long of a download time. When using images, be careful to minimize this issue. Provide alternatives to images (such as text links) and use the alt attribute on your pages. As you continue to create web pages, look back at the guidelines and best practices.
34