100% found this document useful (1 vote)
62 views86 pages

New Perspectives On HTML CSS and XML Comprehensive 4th Edition Edition Patrick Carey - The Ebook Is Ready For Instant Download and Access

The document promotes the 'New Perspectives on HTML, CSS, and XML, 4th Edition' textbook by Patrick Carey, highlighting its comprehensive coverage of web development concepts and practical skills. It emphasizes the hands-on, case-based approach to learning, along with new features like Visual Overviews and ProSkills boxes to enhance the educational experience. The text is designed for both classroom and online instruction, catering to various learning styles and preparing students for real-world applications in web development.

Uploaded by

freidpenezd6
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
62 views86 pages

New Perspectives On HTML CSS and XML Comprehensive 4th Edition Edition Patrick Carey - The Ebook Is Ready For Instant Download and Access

The document promotes the 'New Perspectives on HTML, CSS, and XML, 4th Edition' textbook by Patrick Carey, highlighting its comprehensive coverage of web development concepts and practical skills. It emphasizes the hands-on, case-based approach to learning, along with new features like Visual Overviews and ProSkills boxes to enhance the educational experience. The text is designed for both classroom and online instruction, catering to various learning styles and preparing students for real-world applications in web development.

Uploaded by

freidpenezd6
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 86

Get the full ebook with Bonus Features for a Better Reading Experience on ebookgate.

com

New Perspectives on HTML CSS and XML Comprehensive


4th edition Edition Patrick Carey

https://ebookgate.com/product/new-perspectives-on-html-css-
and-xml-comprehensive-4th-edition-edition-patrick-carey/

OR CLICK HERE

DOWLOAD NOW

Download more ebook instantly today at https://ebookgate.com


Instant digital products (PDF, ePub, MOBI) available
Download now and explore formats that suit you...

New Perspectives on HTML and XHTML Comprehensive New


Perspectives Course Technology Paperback 5th Edition
Patrick M. Carey
https://ebookgate.com/product/new-perspectives-on-html-and-xhtml-
comprehensive-new-perspectives-course-technology-paperback-5th-
edition-patrick-m-carey/
ebookgate.com

HTML and CSS The Comprehensive Guide First Edition Jürgen


Wolf

https://ebookgate.com/product/html-and-css-the-comprehensive-guide-
first-edition-jurgen-wolf/

ebookgate.com

New Perspectives on Microsoft Excel 2010 Comprehensive New


Perspectives Series 1st Edition June Jamrich Parsons

https://ebookgate.com/product/new-perspectives-on-microsoft-
excel-2010-comprehensive-new-perspectives-series-1st-edition-june-
jamrich-parsons/
ebookgate.com

Mastering Integrated HTML and CSS 1st Edition Virginia


Debolt

https://ebookgate.com/product/mastering-integrated-html-and-css-1st-
edition-virginia-debolt/

ebookgate.com
HTML XHTML and CSS Bible 3rd Edition Pfaffenberger B.

https://ebookgate.com/product/html-xhtml-and-css-bible-3rd-edition-
pfaffenberger-b/

ebookgate.com

Head First HTML and CSS 2nd Edition Elisabeth Robson

https://ebookgate.com/product/head-first-html-and-css-2nd-edition-
elisabeth-robson/

ebookgate.com

HTML XHTML and CSS For Dummies 7th Edition Ed Tittel

https://ebookgate.com/product/html-xhtml-and-css-for-dummies-7th-
edition-ed-tittel/

ebookgate.com

Teach Yourself VISUALLY HTML and CSS 1st Edition Mike


Wooldridge

https://ebookgate.com/product/teach-yourself-visually-html-and-
css-1st-edition-mike-wooldridge/

ebookgate.com

New Perspectives on Computer Concepts 2014 Comprehensive


16th Edition June Jamrich Parsons

https://ebookgate.com/product/new-perspectives-on-computer-
concepts-2014-comprehensive-16th-edition-june-jamrich-parsons/

ebookgate.com
New Perspectives on HTML, CSS, and XML, 4th Edition
Textbook Reviewers
We are extremely grateful to the New Perspectives on HTML, CSS, and XML, 4th Edition textbook reviewers
listed below, and would like to take this opportunity to acknowledge them for their contributions in
the development of this text. Their timely reviews, informed feedback, and excellent suggestions were
tremendously valuable and helped us to produce an outstanding text that will meet the needs of all our New
Perspectives instructors and students. Our sincere thanks to all!

Textbook Reviewers
David Doering, St. Louis Community College
Bernice Howard, St. Johns River Community College
Ravinder Kang, Highline Community College
Diana Kokoska, University of Maine at Augusta
Lisa Macon, Valencia Community College
Dave Sciuto, University of Massachusetts—Lowell
Sharon Scollard, Mohawk College
Luke Sui, Daytona State College
John Taylor, Southeastern Technical College

“The New Perspectives on HTML, CSS, and XML, 4th Edition text follows in the tradition of earlier editions with its
hands-on, case-based approach, which has helped thousands of my students succeed in their pursuit of a career in
Web Development. The new pedagogical features, especially the Visual Overviews at the start of each new session, will
appeal to students with a variety of learning styles. The prior edition is a student favorite among text books. I predict
that this new edition will accomplish that which I thought was impossible: to top its predecessor in popularity. Add the
fun students have working through the real-world tutorials to the deep learning that occurs as a result, and we end up
with a student prepared for a high-paying industry career.”
—Lisa Macon,
Valencia Community College

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
New Perspecti ves on

HTML, CSS, and XML


4th Edition

COMPREHENSIVE

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
New Perspecti ves on

HTML, CSS, and XML


4th Edition

COMPREHENSIVE

Patrick Carey
Sasha Vodnik

Australia • Brazil • Japan • Korea • Mexico • Singapore • Spain • United Kingdom • United States

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
This is an electronic version of the print textbook. Due to electronic rights restrictions, some third party content may be suppressed. Editorial
review has deemed that any suppressed content does not materially affect the overall learning experience. The publisher reserves the right to
remove content from this title at any time if subsequent rights restrictions require it. For valuable information on pricing, previous
editions, changes to current editions, and alternate formats, please visit www.cengage.com/highered to search by
ISBN#, author, title, or keyword for materials in your areas of interest.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
New Perspectives on HTML, CSS, and XML © 2014 Cengage Learning
4th Edition, Comprehensive ALL RIGHTS RESERVED. No part of this work covered by the copyright herein may be
Director of Development: Marah Bellegarde reproduced, transmitted, stored or used in any form or by any means graphic, electronic,
Executive Editor: Donna Gridley or mechanical, including but not limited to photocopying, recording, scanning, digitiz-
ing, taping, Web distribution, information networks, or information storage and retrieval
Associate Acquisitions Editor: Amanda Lyons
systems, except as permitted under Section 107 or 108 of the 1976 United States
Product Development Manager: Leigh Hefferon Copyright Act, without the prior written permission of the publisher.
Senior Product Manager: Kathy Finnegan
Product Manager: Julia Leroux-Lindsey For product information and technology assistance, contact us at
Editorial Assistant: Melissa Stehler Cengage Learning Customer & Sales Support, 1-800-354-9706

Brand Manager: Elinor Gregory For permission to use material from this text or product, submit all
requests online at www.cengage.com/permissions
Market Development Managers: Kristie Clark, Further permissions questions can be emailed to
Gretchen Swann [email protected]
Developmental Editor: Pam Conrad
Senior Content Project Manager: Some of the product names and company names used in this book have been used for
Jennifer Goguen McGrail identification purposes only and may be trademarks or registered trademarks of their
Composition: GEX Publishing Services respective manufacturers and sellers.
Art Director: Marissa Falco Microsoft and the Office logo are either registered trademarks or trademarks of
Microsoft Corporation in the United States and/or other countries. Cengage Learning is
Text Designer: Althea Chen
an independent entity from the Microsoft Corporation, and not affiliated with Microsoft
Cover Designer: GEX Publishing Services in any manner.
Cover Art: ©altrendo nature/Stockbyte/Getty Disclaimer: Any fictional data related to persons or companies or URLs used throughout
Images this book is intended for instructional purposes only. At the time this book was printed,
Copyeditor: Suzanne Huizenga any such data was fictional and not belonging to any real persons or companies.
Proofreader: Kathy Orrino Library of Congress Control Number: 2013942735
Indexer: Alexandra Nickerson ISBN-13: 978-1-285-05909-9
ISBN-10: 1-285-05909-3

Cengage Learning
200 First Stamford Place, 4th Floor
Stamford, CT 06902
USA

Cengage Learning is a leading provider of customized learning solutions with office loca-
tions around the globe, including Singapore, the United Kingdom, Australia, Mexico,
Brazil, and Japan. Locate your local office at:
www.cengage.com/global

Cengage Learning products are represented in Canada by Nelson Education, Ltd.

For your course and learning solutions, visit www.cengage.com

Purchase any of our products at your local college store or at our preferred online store
www.cengagebrain.com

ProSkills Icons © 2014 Cengage Learning.

Printed in the United States of America


1 2 3 4 5 6 7 19 18 17 16 15 14 13

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Preface
The New Perspectives Series’ critical-thinking, problem-solving approach is the ideal way
to prepare students to transcend point-and-click skills and take advantage of all that
HTML, CSS, and XML have to offer.
In developing the New Perspectives Series, our goal was to create books that give students
the software concepts and practical skills they need to succeed beyond the classroom.
We’ve updated our proven case-based pedagogy with more practical content to make
learning skills more meaningful to students. With the New Perspectives Series, students
understand why they are learning what they are learning, and are fully prepared to apply
their skills to real-life situations.

“I love this text because


About This Book
it provides detailed This book provides complete coverage of HTML, CSS, and XML and includes the following:
instructions and real- • Up-to-date coverage of using HTML5 and CSS3 to create Web sites
world application • Instruction on creating multimedia Web pages, interactive Web forms, and mobile
examples. It is ideal for
classroom and online
Web sites
instruction. At the end • Creating XML documents and validating them against DTDs or schemas
of the term my students New for this edition!
comment on how much • Each session begins with a Visual Overview, which includes colorful, enlarged fig-
they’ve learned and ures with numerous callouts and key term definitions, giving students a comprehen-
put to use outside the
sive preview of the topics covered in the session, as well as a handy study guide.
classroom.”
—Bernice Howard • New ProSkills boxes provide guidance for how to use the software in real-world,
St. Johns River Community professional situations, and related ProSkills exercises integrate the technology skills
College students learn with one or more of the following soft skills: decision making, prob-
lem solving, teamwork, verbal communication, and written communication.
• Important steps are highlighted in yellow with attached margin notes to help students
pay close attention to completing the steps correctly and avoid time-consuming rework.

System Requirements
This book assumes that students have an Internet connection, a text editor, and a current browser
that supports HTML5 and CSS3. The following is a list of the most recent versions of the major
browsers at the time this text was published: Internet Explorer 10, Firefox 21, Safari 6.0.5, Opera
12.15, and Chrome 27. More recent versions may have come out since the publication of this
book. Students should go to the Web browser home page to download the most current version.
All browsers interpret HTML and CSS code in slightly different ways. It is highly recommended
that students have several different browsers installed on their systems for comparison. Students
might also want to run older versions of these browsers to highlight compatibility issues. Students
who intend to validate their XML documents in Tutorials 12-14 should have access to an XML
validating parser such as Exchanger XML Editor or to an online validation service. The screen-
shots in this book were produced using Internet Explorer 9.0 (Tutorials 1-10) or Internet Explorer
10.0 (Tutorials 11-14) running on Windows 7 Professional (64-bit), unless otherwise noted.
If ­students are using different browsers or operating systems, their screens will vary slightly from
those shown in the book; this should not present any problems in completing the tutorials.
www.cengage.com/series/newperspectives

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
vi New Perspectives Series

“New Perspectives texts


provide up-to-date,
The New Perspectives Approach
real-world application
of content, making book Context
selection easy. The Each tutorial begins with a problem presented in a “real-world” case that is meaningful to
step-by-step, hands-on ­students. The case sets the scene to help students understand what they will do in the tutorial.
approach teaches
students concepts they Hands-on Approach
can apply immediately.” Each tutorial is divided into manageable sessions that combine reading and hands-on, step-by-step
—John Taylor
work. Colorful screenshots help guide students through the steps. Trouble? tips anticipate com-
Southeastern Technical
College
mon mistakes or problems to help students stay on track and continue with the tutorial.

Visual Overview Visual Overviews


New for this edition! Each session begins with a Visual Overview, a new two-page spread that
includes colorful, enlarged figures with numerous callouts and key term definitions, giving
students a comprehensive preview of the topics covered in the session, as well as a handy
study guide.

ProSk ill s ProSkills Boxes and Exercises


New for this edition! ProSkills boxes provide guidance for how to use the software in real-
world, professional situations, and related ProSkills exercises integrate the technology skills
students learn with one or more of the following soft skills: decision making, problem solving,
teamwork, verbal communication, and written communication.

K E Y STEP Key Steps


New for this edition! Important steps are highlighted in yellow with attached margin notes to
help students pay close attention to completing the steps correctly and avoid time-consuming
rework.

insight InSight Boxes


InSight boxes offer expert advice and best practices to help students achieve a deeper under-
standing of the concepts behind the software features and skills.

Margin Tips
Margin Tips provide helpful hints and shortcuts for more efficient use of the software. The Tips
appear in the margin at key points throughout each tutorial, giving students extra information
when and where they need it.

rev iew Assessment


Retention is a key component to learning. At the end of each session, a series of Quick Check
apply
questions helps students test their understanding of the material before moving on. Engaging
end-of-tutorial Review Assignments and Case Problems have always been a hallmark feature of
the New Perspectives Series. Colorful bars and brief descriptions accompany the exercises, mak-
ing it easy to understand both the goal and level of challenge a particular assignment holds.

reference Reference
Within each tutorial, Reference boxes appear before a set of steps to provide a succinct sum-
Glossary/Index mary and preview of how to perform a task. In addition, each book includes a combination
Glossary/Index to promote easy reference of material.

www.cengage.com/series/newperspectives

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive vii

Our Complete System of Instruction


Coverage To Meet Your Needs
Whether you’re looking for just a small amount of coverage or enough to fill a semester-long
class, we can provide you with a textbook that meets your needs.
• Brief books typically cover the essential skills in just 2 to 4 tutorials.
• Introductory books build and expand on those skills and contain an average of 5 to
8 tutorials.
• Comprehensive books are great for a full-semester class, and contain 9 to 12+ tutorials.
So if the book you’re holding does not provide the right amount of coverage for you, there’s
probably another offering available. Go to our Web site or contact your Cengage Learning
sales representative to find out what else we offer.

CourseCasts – Learning on the Go. Always available…always relevant.


Want to keep up with the latest technology trends relevant to you? Visit
http://coursecasts.course.com to find a library of weekly updated podcasts, CourseCasts,
and download them to your mp3 player.

Ken Baldauf, host of CourseCasts, is a faculty member of the Florida State University Computer
Science Department where he is responsible for teaching technology classes to thousands of
FSU students each year. Ken is an expert in the latest technology trends; he gathers and sorts
through the most pertinent news and information for CourseCasts so your students can spend
their time enjoying technology, rather than trying to figure it out. Open or close your lecture
with a discussion based on the latest CourseCast.

Visit us at http://coursecasts.course.com to learn on the go!

Instructor Resources
We offer more than just a book. We have all the tools you need to enhance your lectures, check
students’ work, and generate exams in a new, easier-to-use and completely revised package. This
book’s Instructor’s Manual, ExamView testbank, PowerPoint presentations, data files, solution
files, figure files, and a sample syllabus are all available on a single CD-ROM or for downloading
at http://www.cengage.com.

SAM: Skills Assessment Manager


Get your students workplace-ready with SAM, the premier proficiency-based assessment and
training solution for Microsoft Office! SAM’s active, hands-on environment helps students
master computer skills and concepts that are essential to academic and career success.

Skill-based assessments, interactive trainings, business-centric projects, and comprehensive


remediation engage students in mastering the latest Microsoft Office programs on their own,
allowing instructors to spend class time teaching. SAM’s efficient course setup and robust
grading features provide faculty with consistency across sections. Fully interactive MindTap
Readers integrate market-leading Cengage Learning content with SAM, creating a compre-
hensive online student learning environment.

www.cengage.com/series/newperspectives

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
viii New Perspectives Series

Acknowledgments
I would like to thank the people who worked so hard to make this book possible. Special
thanks to my developmental editor, Sasha Vodnik, for his hard work and valuable insights, and
to my Product Manager, Kathy Finnegan, who has worked tirelessly in overseeing this project
and made my task so much easier with her enthusiasm and good humor. Other people at
Course Technology who deserve credit are Marie Lee, Executive Editor; Julia Leroux-Lindsey,
Associate Product Manager; Jacqueline Lacaire, Editorial Assistant; Jennifer Goguen McGrail,
Senior Content Project Manager; Christian Kunciw, Manuscript Quality Assurance (MQA)
Supervisor; and John Freitas, Serge Palladino, Susan Pedicini, Danielle Shaw, Marianne Snow,
Ashlee Welz Smith, and Susan Whalen, MQA testers.

Feedback is an important part of writing any book, and thanks go to the following reviewers
for their helpful ideas and comments: Bernice Howard, St. Johns River Community College;
Lisa Macon, Valencia Community College; Sharon Scollard, Mohawk College; Luke Sui,
Daytona State College; and John Taylor, Southeastern Technical College.

I want to thank my wife Joan and my six children for their love, encouragement and patience
in putting up with a sometimes distracted husband and father. This book is dedicated to the
memory of Mac Mendelsohn, who generously gave me my chance in this business and whose
constant encouragement in the early years inspired me and taught me so much.
– Patrick Carey

Many thanks to everyone who helped in this revision. Pam Conrad, my sharp-eyed develop-
mental editor, suggested improvements and asked a lot of important questions that helped me
immeasurably in tightening up the material. The good advice of Kathy Finnegan, my product
manager, kept me focused on the important aspects of the revision process, and she sweated
a lot of the small stuff so I didn’t have to. I’m also grateful to Donna Gridley, the series
­executive editor, for keeping the faith during the evolution of this revision. Jen Goguen
McGrail, Kelly Morrison, and the staff at GEX Publishing Services made it all look amazing.
And MQA testers Serge Palladino, Danielle Shaw, and Susan Whalen read everything through,
­completed all the steps, and gave smart feedback that removed many roadblocks for future
users. Finally, thanks to my husband, Jason Bucy, for encouraging me to balance diving deep
into XML with stepping away from the computer, getting outside, and enjoying the world
with him.
– Sasha Vodnik

www.cengage.com/series/newperspectives

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive ix

BRIEF Contents
HTML Level I Tutorials
Tutorial 1 Getting Started with HTML5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 1
Creating a Product Page for a Small Business
Tutorial 2 Developing a Web Site. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 71
Creating a Web Site for Amateur Photographers

Level II Tutorials
Tutorial 3 Designing a Web Page with CSS . . . . . . . . . . . . . . . . . . . . . . HTML 137
Creating a Web Site for a Rural Farm
Tutorial 4 Creating Page Layouts with CSS . . . . . . . . . . . . . . . . . . . . . . HTML 221
Designing a Web Site for a Cycling Club
Tutorial 5 Working with Tables and Columns. . . . . . . . . . . . . . . . . . . . . HTML 317
Creating a Radio Program Schedule

Level III Tutorials


Tutorial 6 Creating a Web Form. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 393
Designing a Survey Form
Tutorial 7 Designing a Multimedia Web Site . . . . . . . . . . . . . . . . . . . . . . HTML 483
Enhancing a Document with Sound, Video, and Applets
Tutorial 8 Enhancing a Web Site with Advanced CSS . . . . . . . . . . . . . . . HTML 547
Designing for Special Effects, Print Media, and the Mobile Web
Tutorial 9 Working with XHTML. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 643
Creating a Well-Formed, Valid Document
Tutorial 10 Programming with JavaScript. . . . . . . . . . . . . . . . . . . . . . . . HTML 685
Hiding E-Mail Addresses on a Library Web Site
Additional Case 1 Creating a Music School Web Site. . . . . . . . . . . . . HTML ADD1
Additional Case 2 Creating a Culinary Web Site. . . . . . . . . . . . . . . . . HTML ADD9
Additional Case 3 Creating a Web Site for a Climbing School. . . . . . HTML ADD16

XML Level IV Tutorials


Tutorial 11 Creating an XML Document. . . . . . . . . . . . . . . . . . . . . . . . . . HTML 743
Developing a Document for SJB Pet Boutique
Tutorial 12 Validating Documents with DTDs. . . . . . . . . . . . . . . . . . . . . . HTML 809
Creating a Document Type Definition for Map Finds For You

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
x New Perspectives Series

Tutorial 13 Validating Documents with Schemas. . . . . . . . . . . . . . . . . . . HTML 875


Creating a Schema for the ATC School of Information Technology
Tutorial 14 Working with Advanced Schemas . . . . . . . . . . . . . . . . . . . . . HTML 941
Creating Advanced Schemas for Higher Ed Test Prep
Appendix A Color Names with Color Values, and HTML Character
Entities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML A1
Appendix B Making the Web More Accessible. . . . . . . . . . . . . . . . . . . . . . HTML B1
Appendix C HTML Elements and Attributes. . . . . . . . . . . . . . . . . . . . . . . HTML C1
Appendix D Cascading Styles and Selectors . . . . . . . . . . . . . . . . . . . . . . HTML D1
Appendix E Frames and Framesets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML E1

Glossary/Index REF 1

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xi

Table of Contents
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . v Marking the Head Element . . . . . . . . . . . . . . . . . . . . . HTML 13

Defining the Page Title . . . . . . . . . . . . . . . . . . . . . HTML 13


HTML Level I Tutorials
Adding Comments . . . . . . . . . . . . . . . . . . . . . . . . HTML 14
Tutorial 1 Getting Started with HTML5
Creating a Product Page for a Small Business . . . . . . . . . HTML 1 Displaying an HTML File . . . . . . . . . . . . . . . . . . . . HTML 15

Defining the Structure of the Page Body . . . . . . . . . . HTML 17


Session 1.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 2
Working with HTML5 Structural Elements . . . . . . HTML 18
Exploring the History of the World Wide Web . . . . . . . HTML 4
Marking a Section with the div Element . . . . . . . HTML 21
Networks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 4
Session 1.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . . HTML 23
Locating Information on a Network . . . . . . . . . . . . HTML 4

Web Pages and Web Servers . . . . . . . . . . . . . . . . . . HTML 5 Session 1.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 24

Introducing HTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 5 Working with Grouping Elements . . . . . . . . . . . . . . . HTML 26

The History of HTML . . . . . . . . . . . . . . . . . . . . . . . . HTML 5 Marking Content Headings . . . . . . . . . . . . . . . . . . HTML 26

XHTML and the Development of HTML5 . . . . . . . . . HTML 6 Grouping Headings . . . . . . . . . . . . . . . . . . . . . . . . HTML 29

HTML and Style Sheets . . . . . . . . . . . . . . . . . . . . . . HTML 7 Marking Paragraph Elements . . . . . . . . . . . . . . . . HTML 30

Tools for Creating HTML Documents . . . . . . . . . . . . HTML 8 Marking a Block Quote . . . . . . . . . . . . . . . . . . . . . HTML 32

Entering Elements and Attributes . . . . . . . . . . . . . . . . HTML 8 Marking an Address . . . . . . . . . . . . . . . . . . . . . . . HTML 33

Introducing HTML Tags . . . . . . . . . . . . . . . . . . . . . . HTML 8 Marking a List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 34

Specifying an Element Attribute . . . . . . . . . . . . . . . HTML 9 Ordered Lists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 35

White Space and HTML . . . . . . . . . . . . . . . . . . . . . . HTML 9 Unordered Lists . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 36

Exploring the Structure of an HTML Document . . . . . HTML 10 Nesting Lists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 37

The Document Type Declaration . . . . . . . . . . . . . . . HTML 11 Description Lists . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 38

Creating the Initial Document . . . . . . . . . . . . . . . . HTML 12

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xii New Perspectives Series

Applying an External Style Sheet . . . . . . . . . . . . . . . HTML 41 Mixed Structures . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 76

Linking to an External Style Sheet . . . . . . . . . . . . HTML 41 Protected Structures . . . . . . . . . . . . . . . . . . . . . . . HTML 78

Styles for HTML5 Elements . . . . . . . . . . . . . . . . . . HTML 42 Creating a Navigation List . . . . . . . . . . . . . . . . . . . . . HTML 79

Marking Text-Level Elements . . . . . . . . . . . . . . . . . . . HTML 45 Working with Hypertext Links . . . . . . . . . . . . . . . . . . HTML 81

Using the Generic Elements div and span . . . . . . . HTML 48 Attributes of the a Element . . . . . . . . . . . . . . . . . . HTML 84

Marking a Line Break . . . . . . . . . . . . . . . . . . . . . . . . . HTML 49 Specifying a Folder Path . . . . . . . . . . . . . . . . . . . . . . HTML 85

Inserting an Inline Image . . . . . . . . . . . . . . . . . . . . . . HTML 52 Absolute Paths . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 87

The img Element . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 52 Relative Paths . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 87

Figures and Figure Captions . . . . . . . . . . . . . . . . . HTML 53 Setting the Base Path . . . . . . . . . . . . . . . . . . . . . . HTML 88

Working with Character Sets and Special Linking to Locations within a Document . . . . . . . . . . HTML 89
Characters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 54
Marking Locations with the id Attribute . . . . . . . HTML 91
Character Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 54
Linking to an id . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 93
Character Encoding . . . . . . . . . . . . . . . . . . . . . . . . HTML 55
Creating Links to ids in Other Documents . . . . . . HTML 95
Character Entity References . . . . . . . . . . . . . . . . . HTML 55
Session 2.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . . HTML 99
Specifying the Character Set . . . . . . . . . . . . . . . . HTML 58
Session 2.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 100
Session 1.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . . HTML 60
Working with Linked Images and Image Maps . . . . HTML 102
Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 61
Introducing Image Maps . . . . . . . . . . . . . . . . . . . HTML 103
Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 63
Client-Side Image Maps . . . . . . . . . . . . . . . . . . . HTML 104
Tutorial 2 Developing a Web Site
Creating a Web Site for Amateur Photographers . . . . HTML 71 Defining Hotspots . . . . . . . . . . . . . . . . . . . . . . . . HTML 104

Session 2.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 72 Applying an Image Map . . . . . . . . . . . . . . . . . . . HTML 107

Exploring Web Site Structures . . . . . . . . . . . . . . . . . . HTML 73 Linking to Resources on the Internet . . . . . . . . . . . . HTML 109

Linear Structures . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 74 Introducing URLs . . . . . . . . . . . . . . . . . . . . . . . . . HTML 109

Hierarchical Structures . . . . . . . . . . . . . . . . . . . . . HTML 76 Linking to a Web Site . . . . . . . . . . . . . . . . . . . . . . HTML 110

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xiii

Linking to FTP Servers . . . . . . . . . . . . . . . . . . . . . . HTML 114 Applying a Style Sheet . . . . . . . . . . . . . . . . . . . . . . . HTML 144

Linking to a Local File . . . . . . . . . . . . . . . . . . . . . . HTML 115 User-Defined Styles . . . . . . . . . . . . . . . . . . . . . . . HTML 145

Linking to an E-Mail Address . . . . . . . . . . . . . . . . . HTML 115 External Style Sheets . . . . . . . . . . . . . . . . . . . . . HTML 146

Working with Hypertext Attributes . . . . . . . . . . . . . . HTML 117 Embedded Style Sheets . . . . . . . . . . . . . . . . . . . HTML 148

Opening a Secondary Window or Tab . . . . . . . . . . HTML 117 Inline Styles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 149

Creating a Tooltip . . . . . . . . . . . . . . . . . . . . . . . . . HTML 119 Exploring the Style Cascade . . . . . . . . . . . . . . . . . . HTML 149

Creating a Semantic Link . . . . . . . . . . . . . . . . . . HTML 120 Style Precedence and Specificity . . . . . . . . . . . . HTML 150

Using the link Element . . . . . . . . . . . . . . . . . . . . HTML 121 Style Inheritance . . . . . . . . . . . . . . . . . . . . . . . . . HTML 150

Working with Metadata . . . . . . . . . . . . . . . . . . . . . . . HTML 121 Defining Important Styles . . . . . . . . . . . . . . . . . . . HTML 151

Using the meta Element . . . . . . . . . . . . . . . . . . . . HTML 121 Writing Style Comments . . . . . . . . . . . . . . . . . . . . . . HTML 151

Using the meta Element to Reload a Defining Color in CSS . . . . . . . . . . . . . . . . . . . . . . . . HTML 152
Web Page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 124
RGB Color Values . . . . . . . . . . . . . . . . . . . . . . . . . HTML 152
Session 2.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 124
Using Color Names . . . . . . . . . . . . . . . . . . . . . . . HTML 154
Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 125
Defining Text and Background Colors . . . . . . . . . HTML 156
Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 127
Enhancements to Color in CSS3 . . . . . . . . . . . . . . . . HTML 158
ProSkills Exercise: Written Communication . . . . . . . HTML 135
HSL Color Values . . . . . . . . . . . . . . . . . . . . . . . . . HTML 158

HTML Level II Tutorials Opacity Values in CSS3 . . . . . . . . . . . . . . . . . . . . HTML 159

Tutorial 3 Designing a Web Page with CSS Styles Using Progressive Enhancement . . . . . . . . HTML 160
Creating a Web Site for a Rural Farm . . . . . . . . . . . . . HTML137
Session 3.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . . HTML 161
Session 3.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 138
Session 3.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 162
Introducing CSS . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 140
Exploring Selector Patterns . . . . . . . . . . . . . . . . . . . HTML 164
The History of CSS . . . . . . . . . . . . . . . . . . . . . . . . HTML 142
Contextual Selectors . . . . . . . . . . . . . . . . . . . . . . HTML 165
Browser Extensions . . . . . . . . . . . . . . . . . . . . . . . HTML 143
Attribute Selectors . . . . . . . . . . . . . . . . . . . . . . . HTML 168
Defining a Style Rule . . . . . . . . . . . . . . . . . . . . . . . . HTML 144

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xiv New Perspectives Series

Styling Web Page Text . . . . . . . . . . . . . . . . . . . . . . . . HTML 171 Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 211

Choosing the Text Font . . . . . . . . . . . . . . . . . . . . . HTML 171 Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 214

Setting the Font Size . . . . . . . . . . . . . . . . . . . . . . HTML 174 Tutorial 4 Creating Page Layouts with CSS
Designing a Web Site for a Cycling Club . . . . . . . . . . . HTML 221
Controlling Spacing and Indentation . . . . . . . . . HTML 176
Session 4.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 222
Working with Font Styles . . . . . . . . . . . . . . . . . . . HTML 180
Exploring Display Styles . . . . . . . . . . . . . . . . . . . . . . HTML 224
Aligning Text Horizontally and Vertically . . . . . . HTML 182
The display style . . . . . . . . . . . . . . . . . . . . . . HTML 225
Combining All Text Formatting in a
Single Style . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 183 The Box Model . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 226

Working with Web Fonts . . . . . . . . . . . . . . . . . . . . . HTML 185 Creating a Reset Style Sheet . . . . . . . . . . . . . . . . . . HTML 227

The @font-face Rule . . . . . . . . . . . . . . . . . . . . HTML 186 Designing the Background . . . . . . . . . . . . . . . . . . . . HTML 229

Installing a Cross-Browser Web Font . . . . . . . . . HTML 187 Background Image Options . . . . . . . . . . . . . . . . HTML 230

Understanding the CSS @rules . . . . . . . . . . . . . HTML 189 CSS3 Background Styles . . . . . . . . . . . . . . . . . . . HTML 231

Session 3.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . . HTML 191 The background Shorthand Property . . . . . HTML 233

Session 3.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 192 Multiple Image Backgrounds . . . . . . . . . . . . . . . HTML 234

Designing Styles for Lists . . . . . . . . . . . . . . . . . . . . . HTML 194 Adding a Page Background . . . . . . . . . . . . . . . . . HTML 235

Choosing a List Style Type . . . . . . . . . . . . . . . . . . HTML 194 Exploring Browser Extensions . . . . . . . . . . . . . . . . . HTML 236

Using Images for List Markers . . . . . . . . . . . . . . HTML 196 Exploring Layout Designs . . . . . . . . . . . . . . . . . . . . . HTML 237

Changing the List Layout . . . . . . . . . . . . . . . . . . HTML 198 Fixed, Fluid, and Elastic Layouts . . . . . . . . . . . . . HTML 239

Using Pseudo-Classes and Pseudo-Elements . . . . . . HTML 200 Setting the Page Width and Height . . . . . . . . . . HTML 240

Pseudo-Classes . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 200 Floating Elements . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 242

Pseudo-Elements . . . . . . . . . . . . . . . . . . . . . . . . . HTML 204 Setting a Float . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 242

Session 3.3 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 210 Clearing a Float . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 246

Session 4.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 249

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xv

Session 4.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 250 Stacking Elements . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 300

Setting Margins and Padding . . . . . . . . . . . . . . . . . HTML 252 Session 4.3 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 303

Margin Styles . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 252 Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 304

Padding Styles . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 256 Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 306

Working with Borders . . . . . . . . . . . . . . . . . . . . . . . . HTML 262 Tutorial 5 Working with Tables and Columns
Creating a Radio Program Schedule . . . . . . . . . . . . . . HTML 317
Setting Border Width and Color . . . . . . . . . . . . . HTML 263
Session 5.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 318
Setting the Border Design . . . . . . . . . . . . . . . . . . HTML 264
Introducing Web Tables . . . . . . . . . . . . . . . . . . . . . . HTML 320
Creating Rounded Corners . . . . . . . . . . . . . . . . . . . . HTML 266
Marking Tables and Table Rows . . . . . . . . . . . . . HTML 321
Elongated Corners . . . . . . . . . . . . . . . . . . . . . . . . HTML 267
Marking Table Headings and Table Data . . . . . . .HTML 323
Browser Extensions to Rounded Corners . . . . . . HTML 268
Adding a Table Border . . . . . . . . . . . . . . . . . . . . HTML 325
Managing Your Layout . . . . . . . . . . . . . . . . . . . . . . . HTML 270
Spanning Rows and Columns . . . . . . . . . . . . . . . . . . HTML 327
Using the Outline Style . . . . . . . . . . . . . . . . . . . . HTML 271
Creating a Table Caption . . . . . . . . . . . . . . . . . . . . . HTML 333
Putting It All Together . . . . . . . . . . . . . . . . . . . . HTML 273
Marking Row Groups . . . . . . . . . . . . . . . . . . . . . . . . HTML 336
Session 4.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 281
Marking Column Groups . . . . . . . . . . . . . . . . . . . . . HTML 338
Session 4.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 282
Adding a Table Summary . . . . . . . . . . . . . . . . . . . . . HTML 342
Positioning Objects . . . . . . . . . . . . . . . . . . . . . . . . . HTML 284
Session 5.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 343
Absolute Positioning . . . . . . . . . . . . . . . . . . . . . . HTML 284
Session 5.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 344
Relative Positioning . . . . . . . . . . . . . . . . . . . . . . . HTML 287
Formatting Tables with HTML Attributes . . . . . . . . . HTML 346
Fixed and Inherited Positioning . . . . . . . . . . . . . HTML 290
Setting Cell Spacing with HTML . . . . . . . . . . . . . HTML 346
Absolute Positioning and Element Widths . . . . . HTML 295
Setting Cell Padding with HTML . . . . . . . . . . . . . HTML 346
Working with Overflow and Clipping . . . . . . . . . . . . HTML 296
Setting Table Widths and Heights in HTML . . . . HTML 348
Horizontal Overflow and White Space . . . . . . . . HTML 299
Setting Row Heights with HTML . . . . . . . . . . . . . HTML 349
Clipping an Element . . . . . . . . . . . . . . . . . . . . . . HTML 299

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xvi New Perspectives Series

Formatting Table Borders with HTML . . . . . . . . . HTML 349 Creating a Web Form . . . . . . . . . . . . . . . . . . . . . . . . HTML 399

Aligning Cell Contents with HTML . . . . . . . . . . . HTML 351 Interacting with a Web Server . . . . . . . . . . . . . . HTML 400

Vertical Alignment in HTML . . . . . . . . . . . . . . . . HTML 351 Creating a Field Set . . . . . . . . . . . . . . . . . . . . . . . . . HTML 402

Formatting Tables with CSS . . . . . . . . . . . . . . . . . . . HTML 353 Creating Input Boxes . . . . . . . . . . . . . . . . . . . . . . . . HTML 404

Table Border Styles . . . . . . . . . . . . . . . . . . . . . . . HTML 353 Adding Field Labels . . . . . . . . . . . . . . . . . . . . . . . . . HTML 408

Applying Styles to Rows and Columns . . . . . . . . HTML 358 Applying a Style Sheet to a Web Form . . . . . . . . . . . HTML 411

Using the Width and Height Styles . . . . . . . . . . . HTML 362 Defining Default Values and Placeholders . . . . . . . . HTML 415

Caption Styles . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 367 Session 6.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 419

Applying Table Styles to Other Page Elements . . . . HTML 369 Session 6.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . .HTML 420
Creating Columnar Layouts . . . . . . . . . . . . . . . . . . . HTML 371 Creating a Selection List . . . . . . . . . . . . . . . . . . . . . HTML 422
CSS3 Column Styles . . . . . . . . . . . . . . . . . . . . . . HTML 372 Setting the Size of the Selection List . . . . . . . . . HTML 425
Browser Extensions to Columns . . . . . . . . . . . . . HTML 373 Allowing for Multiple Selections . . . . . . . . . . . . . HTML 427
Session 5.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 377 Grouping Selection Options . . . . . . . . . . . . . . . . HTML 428
Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 378 Creating Option Buttons . . . . . . . . . . . . . . . . . . . . . HTML 429
Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 380 Creating a Text Area Box . . . . . . . . . . . . . . . . . . . . . HTML 434
ProSkills Exercise: Problem Solving . . . . . . . . . . . . . HTML 391 Creating Check Boxes . . . . . . . . . . . . . . . . . . . . . . . . HTML 437

Session 6.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 441


HTML Level III Tutorials
Tutorial 6 Creating a Web Form Session 6.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 442
Designing a Survey Form . . . . . . . . . . . . . . . . . . . . . . . HTML 393
Exploring HTML5 Data Types . . . . . . . . . . . . . . . . . . HTML 444
Session 6.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 394
The email, tel, and url Data Types . . . . . . HTML 445
Introducing Web Forms . . . . . . . . . . . . . . . . . . . . . . HTML 396
Specifying Dates and Times . . . . . . . . . . . . . . . . HTML 446
Parts of a Web Form . . . . . . . . . . . . . . . . . . . . . . HTML 397
Using the number Data Type . . . . . . . . . . . . . . HTML 447
Forms and Server-Based Programs . . . . . . . . . . . HTML 398
Specifying a Numeric Range with the range
Data Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 450

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xvii

Suggesting Options with Data Lists . . . . . . . . . . . . . HTML 454 Using the HTML5 audio Element . . . . . . . . . . . . . HTML 492

Creating Form Buttons . . . . . . . . . . . . . . . . . . . . . . . HTML 456 Understanding the source Element . . . . . . . . HTML 492

Creating a Command Button . . . . . . . . . . . . . . . HTML 456 Attributes of the audio Element . . . . . . . . . . . HTML 493

Creating Submit and Reset Buttons . . . . . . . . . . HTML 457 Working with Embedded Objects . . . . . . . . . . . . . . HTML 496

Designing a Custom Button . . . . . . . . . . . . . . . . .HTML 460 MIME Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 497

Validating a Web Form . . . . . . . . . . . . . . . . . . . . . . . HTML 460 Plug-In Attributes . . . . . . . . . . . . . . . . . . . . . . . . HTML 498

Indicating Required Values . . . . . . . . . . . . . . . . . HTML 461 Session 7.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 501

Validating Based on Data Type . . . . . . . . . . . . . . HTML 463 Session 7.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 502
Testing for a Valid Pattern . . . . . . . . . . . . . . . . . . HTML 464 Exploring Digital Video . . . . . . . . . . . . . . . . . . . . . . HTML 504
Applying Inline Validation . . . . . . . . . . . . . . . . . . . . HTML 466 Bit Rates and Video Quality . . . . . . . . . . . . . . . . . HTML 504
Using the focus Pseudo-Class . . . . . . . . . . . . . HTML 466 File Formats and Codecs . . . . . . . . . . . . . . . . . . . HTML 504
Pseudo-Classes for Valid and Invalid Data . . . . . HTML 468 Video Formats under HTML5 . . . . . . . . . . . . . . . . HTML 505
Session 6.3 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 470 Using the HTML5 video Element . . . . . . . . . . . . . HTML 506
Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 471 Adding Video Captions with Web Tracks . . . . . . HTML 509
Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 474 Introducing the object Element . . . . . . . . . . . . . HTML 509
Tutorial 7 Designing a Multimedia Web Site
Working with Flash . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 510
Enhancing a Document with Sound, Video,
and Applets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 483 Flash and Apple . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 511

Session 7.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 484 Embedding a Flash Player . . . . . . . . . . . . . . . . . . . HTML 511

Introducing Multimedia on the Web . . . . . . . . . . . . HTML 486 Working with Flash Parameters . . . . . . . . . . . . . . HTML 512

Multimedia Sites and Bandwidth . . . . . . . . . . . . HTML 487 Nesting a Hypertext Link . . . . . . . . . . . . . . . . . . HTML 515

Understanding Plug-Ins . . . . . . . . . . . . . . . . . . . HTML 487 Embedding Videos from YouTube . . . . . . . . . . . . . . . HTML 516

Exploring Digital Audio . . . . . . . . . . . . . . . . . . . . . . HTML 488

Audio Formats under HTML5 . . . . . . . . . . . . . . . HTML 491

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xviii New Perspectives Series

The object Element and ActiveX . . . . . . . . . . . . HTML 518 Introducing Internet Explorer Filters . . . . . . . . . . . . HTML 558

The classid Attribute . . . . . . . . . . . . . . . . . . HTML 518 The Shadow and DropShadow Filters . . . . . HTML 559

The codebase Attribute . . . . . . . . . . . . . . . . . HTML 519 Combining Several Filters . . . . . . . . . . . . . . . . . . HTML 561

Session 7.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 521 Rotating an Object . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 561

Session 7.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 522 The transform Styles . . . . . . . . . . . . . . . . . . HTML 561

Introducing Java . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 524 Transformations in Three Dimensions . . . . . . . . . HTML 565

Working with Java Applets . . . . . . . . . . . . . . . . . . . HTML 525 Applying a Color Gradient . . . . . . . . . . . . . . . . . . . . HTML 567

Embedding a Java Applet . . . . . . . . . . . . . . . . . . HTML 525 Creating Linear Gradients with CSS3 . . . . . . . . . HTML 567

Inserting Java Parameters . . . . . . . . . . . . . . . . . HTML 526 Creating Radial Gradients with CSS3 . . . . . . . . . HTML 570

Embedding Java with the applet Element . . . HTML 532 Defining Gradients with Browser Extensions . . . HTML 571

Embedding Other Objects . . . . . . . . . . . . . . . . . . . . HTML 534 Repeating a Gradient . . . . . . . . . . . . . . . . . . . . . HTML 576

Inserting Inline Images . . . . . . . . . . . . . . . . . . . . HTML 534 Session 8.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 579

Embedding an HTML File . . . . . . . . . . . . . . . . . . HTML 534 Session 8.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . .HTML 580

Session 7.3 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 536 Applying a Border Image . . . . . . . . . . . . . . . . . . . . . HTML 582

Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 537 Creating Semi-Transparent Objects . . . . . . . . . . . . . HTML 585

Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 540 Working with Different Media Devices . . . . . . . . . . HTML 588

Tutorial 8 Enhancing a Web Site with Advanced CSS Media Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 588
Designing for Special Effects, Print Media, and the
Mobile Web . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 547 The @media and @import Rules . . . . . . . . . HTML 589

Session 8.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 548 Media Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 590

Creating Drop Shadows with CSS3 . . . . . . . . . . . . . HTML 550 Using Print Styles . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 595

Creating a Text Shadow . . . . . . . . . . . . . . . . . . . HTML 551 Page Pseudo-Classes . . . . . . . . . . . . . . . . . . . . . . HTML 596

Creating a Box Shadow . . . . . . . . . . . . . . . . . . . . HTML 554 Page Names and the Page Property . . . . . . . . . . HTML 596

Setting the Page Size . . . . . . . . . . . . . . . . . . . . . HTML 597

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xix

Working with Page Breaks . . . . . . . . . . . . . . . . . . . . HTML 598 HTML as an SGML Application . . . . . . . . . . . . . . HTML 646

Preventing a Page Break . . . . . . . . . . . . . . . . . . . HTML 599 XML and XHTML . . . . . . . . . . . . . . . . . . . . . . . . . HTML 647

Working with Widows and Orphans . . . . . . . . . . HTML 599 Creating an XHTML Document . . . . . . . . . . . . . . HTML 648

Session 8.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 605 Creating Well-Formed Documents . . . . . . . . . . . . . . HTML 650

Session 8.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 606 Creating Valid XHTML Documents . . . . . . . . . . . . . . HTML 652

Designing for the Mobile Web . . . . . . . . . . . . . . . . . HTML 608 Transitional, Frameset, and Strict DTDs . . . . . . . HTML 653

Testing a Mobile Design . . . . . . . . . . . . . . . . . . . . . . HTML 609 The Valid Use of Attributes . . . . . . . . . . . . . . . . . HTML 654

Configuring the Viewport . . . . . . . . . . . . . . . . . . . . HTML 610 Inserting the DOCTYPE Declaration . . . . . . . . . . HTML 656

The Viewport meta Element . . . . . . . . . . . . . . . HTML 612 Setting the XHTML Namespace . . . . . . . . . . . . . . . . HTML 658

Introducing Media Queries . . . . . . . . . . . . . . . . . . . HTML 613 HTML5 and XHTML . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 660

The media Attribute in CSS3 . . . . . . . . . . . . . . HTML 613 Session 9.1 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 663

Writing a Feature Expression . . . . . . . . . . . . . . . HTML 615 Session 9.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 664

Choosing a Media Query for the Mobile Web . . . HTML 616 Validating Under XHTML Transitional . . . . . . . . . . . HTML 666

Creating a Mobile Style Sheet . . . . . . . . . . . . . . . . . HTML 619 Testing Under XHTML Strict . . . . . . . . . . . . . . . . . . . HTML 670

Designing for Portrait Orientation . . . . . . . . . . . HTML 621 Using Embedded Style Sheets in XHTML . . . . . . . . . HTML 675

Designing for Landscape Orientation . . . . . . . . . HTML 624 Session 9.2 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 677

Session 8.3 Quick Check . . . . . . . . . . . . . . . . . . . . . . HTML 627 Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 678

Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 628 Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 679

Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 632 Tutorial 10 Programming with JavaScript


Hiding E-Mail Addresses on a Library Web Site . . . . . HTML 685
Tutorial 9 Working with XHTML
Creating a Well-Formed, Valid Document . . . . . . . . . . HTML 643 Session 10.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 686

Session 9.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 644 Introducing JavaScript . . . . . . . . . . . . . . . . . . . . . . . HTML 688

Introducing XHTML . . . . . . . . . . . . . . . . . . . . . . . . . HTML 646 Server-Side and Client-Side Programming . . . . . HTML 690

SGML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 646 The Development of JavaScript . . . . . . . . . . . . . HTML 692

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xx New Perspectives Series

Working with the script Element . . . . . . . . . . . . HTML 693 Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 731

Creating a script Element . . . . . . . . . . . . . . . HTML 693 Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 732

Placing the script Element . . . . . . . . . . . . . . HTML 694 ProSkills Exercise: Teamwork . . . . . . . . . . . . . . . . . HTML 740

Writing a JavaScript Statement . . . . . . . . . . . . . HTML 694 Additional Case 1 Creating a Music School
Web Site. . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML ADD1
Writing Output to a Web Document . . . . . . . . . . . . HTML 695
Additional Case 2 Creating a Culinary
The document.write() Method . . . . . . . HTML 696
Web Site. . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML ADD9
Understanding JavaScript Syntax . . . . . . . . . . . . . . HTML 699 Additional Case 3 Creating a Web
Working with Variables . . . . . . . . . . . . . . . . . . . . . . HTML 700 Site for a Climbing School. . . . . . . . . . . . . . HTML ADD16

Declaring a Variable . . . . . . . . . . . . . . . . . . . . . . HTML 700


XML Level IV Tutorials
Assigning a Value to a Variable . . . . . . . . . . . . . . HTML 701
Tutorial 11 Creating an XML Document
Developing a Document for SJB Pet Boutique . . . . . . HTML 743
Working with Data Types . . . . . . . . . . . . . . . . . . HTML 703

Session 10.1 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 707 Session 11.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 744

Introducing XML . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 746


Session 10.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 708
The Roots of XML . . . . . . . . . . . . . . . . . . . . . . . . . HTML 746
Writing a JavaScript Function . . . . . . . . . . . . . . . . . HTML 710
XML Today . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 746
Calling a Function . . . . . . . . . . . . . . . . . . . . . . . . . HTML 711
XML with Software Applications and
Creating a Function to Return a Value . . . . . . . . HTML 716
Languages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 747
Accessing an External JavaScript File . . . . . . . . . . . HTML 717
XML and Databases . . . . . . . . . . . . . . . . . . . . . . . HTML 747
Commenting JavaScript Code . . . . . . . . . . . . . . . . . HTML 722
XML and Mobile Development . . . . . . . . . . . . . . HTML 748
Inserting Single-Line and Multiline Comments . HTML 722
Creating an XML Vocabulary . . . . . . . . . . . . . . . . HTML 749
Debugging Your JavaScript Programs . . . . . . . . . . . HTML 724
Standard XML Vocabularies . . . . . . . . . . . . . . . . HTML 750
Debugging Tools and Techniques . . . . . . . . . . . . . . HTML 727
DTDs and Schemas . . . . . . . . . . . . . . . . . . . . . . . HTML 753
Session 10.2 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 730
Well-Formed and Valid XML Documents . . . . . . . HTML 753

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xxi

Creating an XML Document . . . . . . . . . . . . . . . . . . . HTML 753 Inserting a Processing Instruction . . . . . . . . . . . . . . HTML 790

The Structure of an XML Document . . . . . . . . . . HTML 754 Working with Namespaces . . . . . . . . . . . . . . . . . . . . HTML 793

The XML Declaration . . . . . . . . . . . . . . . . . . . . . . HTML 754 Declaring a Namespace . . . . . . . . . . . . . . . . . . . HTML 793

Inserting Comments . . . . . . . . . . . . . . . . . . . . . . HTML 757 Applying a Default Namespace . . . . . . . . . . . . . HTML 793

Processing an XML Document . . . . . . . . . . . . . . . . . HTML 759 Session 11.2 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 795

XML Parsers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 759 Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 796

Session 11.1 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 765 Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 798

Tutorial 12 Validating Documents with DTDs


Session 11.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 766
Creating a Document Type Definition for Map Finds
Working with Elements . . . . . . . . . . . . . . . . . . . . . . HTML 768 For You . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 809

Empty Elements . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 769 Session 12.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 810

Nesting Elements . . . . . . . . . . . . . . . . . . . . . . . . HTML 769 Creating a Valid Document . . . . . . . . . . . . . . . . . . . HTML 812

The Element Hierarchy . . . . . . . . . . . . . . . . . . . . HTML 770 Declaring a DTD . . . . . . . . . . . . . . . . . . . . . . . . . HTML 815

Charting the Element Hierarchy . . . . . . . . . . . . . HTML 772 Writing the Document Type Declaration . . . . . . . HTML 818

Writing the Document Body . . . . . . . . . . . . . . . . HTML 774 Declaring Document Elements . . . . . . . . . . . . . . . . . HTML 819

Working with Attributes . . . . . . . . . . . . . . . . . . . . . . HTML 776 Elements Containing Any Type of Content . . . . . HTML 820

Using Character and Entity References . . . . . . . . . . HTML 779 Empty Elements . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 820

Understanding Text Characters and White Space . . . HTML 783 Elements Containing Parsed Character Data . . . HTML 821

Parsed Character Data . . . . . . . . . . . . . . . . . . . . HTML 783 Working with Child Elements . . . . . . . . . . . . . . . . . . HTML 822

Character Data . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 783 Specifying an Element Sequence . . . . . . . . . . . . HTML 822

White Space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 784 Specifying an Element Choice . . . . . . . . . . . . . . . HTML 823

Creating a CDATA Section . . . . . . . . . . . . . . . . . . HTML 784 Modifying Symbols . . . . . . . . . . . . . . . . . . . . . . . HTML 824

Formatting XML Data with CSS . . . . . . . . . . . . . . . . HTML 788 Session 12.1 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 827

Applying a Style to an Element . . . . . . . . . . . . . . HTML 789

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xxii New Perspectives Series

Session 12.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 828 Tutorial 13 Validating Documents with Schemas


Creating a Schema for the ATC School of
Declaring Attributes . . . . . . . . . . . . . . . . . . . . . . . . . HTML 830 Information Technology . . . . . . . . . . . . . . . . . . . . . . . . HTML 875

Working with Attribute Types . . . . . . . . . . . . . . . . . HTML 833


Session 13.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 876
Character Data . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 834
Introducing XML Schema . . . . . . . . . . . . . . . . . . . . . HTML 878
Enumerated Types . . . . . . . . . . . . . . . . . . . . . . . . HTML 835
The Limits of DTDs . . . . . . . . . . . . . . . . . . . . . . . HTML 879
Tokenized Types . . . . . . . . . . . . . . . . . . . . . . . . . HTML 836
Schemas and DTDs . . . . . . . . . . . . . . . . . . . . . . . HTML 879
Working with Attribute Defaults . . . . . . . . . . . . . . . HTML 839
Schema Vocabularies . . . . . . . . . . . . . . . . . . . . . . HTML 880
Validating an XML Document . . . . . . . . . . . . . . . . . . HTML 841
Starting a Schema File . . . . . . . . . . . . . . . . . . . . . . . HTML 881
Session 12.2 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 847
Understanding Simple and Complex Types . . . . . . . HTML 883

Session 12.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 848 Defining a Simple Type Element . . . . . . . . . . . . . . . HTML 884

Introducing Entities . . . . . . . . . . . . . . . . . . . . . . . . . HTML 850 Defining an Attribute . . . . . . . . . . . . . . . . . . . . . . . . HTML 885

Working with General Entities . . . . . . . . . . . . . . . . . HTML 850 Defining a Complex Type Element . . . . . . . . . . . . . . HTML 887

Creating Parsed Entities . . . . . . . . . . . . . . . . . . . HTML 851 Defining an Element Containing Only


Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 888
Referencing a General Entity . . . . . . . . . . . . . . . . HTML 852
Defining an Element Containing Attributes and
Working with Parameter Entities . . . . . . . . . . . . . . . HTML 857
Basic Text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 888
Inserting Comments into a DTD . . . . . . . . . . . . . . . . HTML 859
Referencing an Element or Attribute
Creating Conditional Sections . . . . . . . . . . . . . . . . . HTML 860 Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 889

Working with Unparsed Data . . . . . . . . . . . . . . . . . . HTML 861 Defining an Element with Nested Children . . . . . HTML 891

Validating Standard Vocabularies . . . . . . . . . . . . . . HTML 863 Defining an Element Containing Nested


Elements and Attributes . . . . . . . . . . . . . . . . . . . HTML 893
Session 12.3 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 865
Indicating Required Attributes . . . . . . . . . . . . . . . . HTML 896
Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 866
Specifying the Number of Child Elements . . . . . . . . HTML 898
Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 867

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML, CSS, and XML 4th Edition, Comprehensive xxiii

Validating a Schema Document . . . . . . . . . . . . . . . . HTML 899 Russian Doll Design . . . . . . . . . . . . . . . . . . . . . . . HTML 946

Applying a Schema to an Instance Document . . . . . HTML 901 Venetian Blind Design . . . . . . . . . . . . . . . . . . . . . HTML 948

Session 13.1 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 905 Session 14.1 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 951

Session 13.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 906 Session 14.2 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 952

Validating with Built-In Data Types . . . . . . . . . . . . . HTML 908 Combining XML Vocabularies . . . . . . . . . . . . . . . . . HTML 954

String Data Types . . . . . . . . . . . . . . . . . . . . . . . . HTML 909 Creating a Compound Document . . . . . . . . . . . . HTML 956

Numeric Data Types . . . . . . . . . . . . . . . . . . . . . . HTML 910 Understanding Name Collision . . . . . . . . . . . . . . HTML 958

Data Types for Dates and Times . . . . . . . . . . . . . . HTML 911 Working with Namespaces in an Instance
Document . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 959
Deriving Customized Data Types . . . . . . . . . . . . . . . HTML 914
Declaring and Applying a Namespace
Deriving a List Data Type . . . . . . . . . . . . . . . . . . HTML 916
to a Document . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 959
Deriving a Union Data Type . . . . . . . . . . . . . . . . HTML 916
Applying a Namespace to an Element . . . . . . . . HTML 961
Deriving a Restricted Data Type . . . . . . . . . . . . . HTML 917
Working with Attributes . . . . . . . . . . . . . . . . . . . HTML 963
Deriving Data Types Using Regular Expressions . . . HTML 923
Associating a Schema with a Namespace . . . . . . . . HTML 965
Introducing Regular Expressions . . . . . . . . . . . . HTML 924
Targeting a Namespace . . . . . . . . . . . . . . . . . . . HTML 965
Applying a Regular Expression . . . . . . . . . . . . . . HTML 926
Including and Importing Schemas . . . . . . . . . . . HTML 968
Session 13.2 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 929
Referencing Objects from Other Schemas . . . . . HTML 969
Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 930
Combining Standard Vocabularies . . . . . . . . . . . . . . HTML 971
Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 931
Session 14.2 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 973
Tutorial 14 Working with Advanced Schemas
Creating Advanced Schemas for Higher Ed Session 14.3 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 974
Test Prep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 941
Adding a Namespace to a Style Sheet . . . . . . . . . . . HTML 976
Session 14.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 942
Declaring a Namespace in a Style Sheet . . . . . . HTML 978
Designing a Schema . . . . . . . . . . . . . . . . . . . . . . . . . HTML 944
Qualifying Elements and Attributes by
Flat Catalog Design . . . . . . . . . . . . . . . . . . . . . . . HTML 944 Default . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 980

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
xxiv New Perspectives Series

Session 14.3 Quick Check . . . . . . . . . . . . . . . . . . . . . HTML 985 Appendix B Making the Web More Accessible. . HTML B1

Review Assignments . . . . . . . . . . . . . . . . . . . . . . . . . HTML 986 Appendix C HTML Elements and Attributes. . . HTML C1

Case Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTML 987 Appendix D Cascading Styles and Selectors. . . HTML D1

ProSkills Exercise: Decision Making . . . . . . . . . . . . . HTML 995 Appendix E Frames and Framesets. . . . . . . . . . HTML E1

Appendix A Color Names with Color Values, Glossary/Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . REF 1


and HTML Character Entities . . . . . . . . . . . . . . HTML A1

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
TUTORIAL
1
O B J E C TIV ES Getting Started
Session 1.1
• Explore the history of the
Internet, the Web, and HTML
with HTML5
• Compare the different versions Creating a Product Page for a Small
of HTML
• Study the syntax of HTML tags Business
and attributes
• Define a Web page head,
body, and title Case | The J-Prop Shop
• Work with the HTML5
structural elements Dave Vinet owns a small business called the J-Prop Shop that builds
and sells circus props and equipment. Dave is looking to expand
Session 1.2
• Mark page headings, his business and his visibility by upgrading his Web site. Dave has
paragraphs, block quotes, and already written the text for the Web site’s home page and has gener-
addresses ated some of the graphic images for it. He has come to you for help
• Create unordered and in designing a Web page and writing the code. Dave hopes to build
ordered lists on his Web page in the future as his business expands, so he would
• Apply an external style sheet to like you to write code that takes advantage of the latest Web stan-
a Web page dards, including HTML5. Your job will be to create a sample home
• Run a JavaScript program page that Dave can use as a foundation for his new Web site.
• Mark text-level elements
including strong and
emphasized text
• Insert inline images and
line breaks
• Insert special characters from
extended character sets

STARTING DATA FILES

tutorial.01 tutorial review case1 case2

jpslogo.png basiclogo.png mhlogo.jpg macbeth.jpg


jpsstyles.css basicstick.png mhstyles.css macbethtxt.htm
modernizr-1.5.js basicstyles.css mhtxt.htm macstyles.css
stick.txt modernizr-1.5.js modernizr-1.5.js
modernizr-1.5.js

case3 case4 demo

dessertstyles.css logo.jpg cengage.jpg


dessertweb.jpg smith.jpg demo.gif
modernizr-1.5.js smith.txt demo_characters.htm
torte.jpg demo_html.htm
tortetxt.htm demo2.gif
modernizr-1.5.js

HTML 1

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 2 HTML and CSS | Tutorial 1 Getting Started with HTML5

SESSION 1.1 VISUAL OVERVIEW


The doctype statement The head element provides
indicates the markup information and instructions
language of the to the browser about the
document. document.

Structure of an HTML file

Resulting Web page


HTML comments
document the
HTML code.

HTML structural
The contents of elements define
the title element the basic
appear in the structure of the
browser title bar. contents of the
Web page.

The body
element contains
the content of
the page body.

The section
element marks a
major section of
the Web page.
The article element
contains content about a
specific area of interest.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 3

THE STRUCTURE OF AN HTML5 DOCUMENT


The header element
contains an introduction
to the page.

Markup Tags
Document
elements are
marked
using tags.

Resulting Web page

Two-sided tags mark elements that


contain textual content or other elements

opening tag element closing tag


content

One-sided tags mark elements that


contain no textual content
The footer element The aside element
contains address and contains extra content
summary information. on the page.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 4 HTML and CSS | Tutorial 1 Getting Started with HTML5

Exploring the History of the World Wide Web


Before you start creating a Web page for Dave, it will be helpful to first look at the his-
tory of the Web and the development of HTML. You’ll start by reviewing networks and
learn how they led to the creation of the World Wide Web.

Networks
A network is a structure that allows devices known as nodes or hosts to be linked
together to share information and services. Hosts can include devices such as comput-
ers, printers, and scanners because they are all capable of sending and receiving data
electronically over a network.
A host that provides information or a service is called a server. For example, a print
server is a network host that provides printing services to the network; a file server is
a host that provides storage space for saving and retrieving files. A computer or other
device that receives a service is called a client. Networks can follow several different
designs based on the relationship between the servers and the clients. One of the most
commonly used designs is the client-server network in which several clients access
information provided by one or more servers. You might be using such a network to
access your data files for this tutorial.
Networks can also be classified based on the range they cover. A network confined to
a small geographic area, such as within a building or department, is referred to as a local
area network or LAN. A network that covers a wider area, such as several buildings or
cities, is called a wide area network or WAN. Wide area networks typically consist of
two or more interconnected local area networks.
The largest WAN in existence is the Internet, which incorporates an almost uncount-
able number of networks and hosts involving computers, mobile phones, PDAs, MP3
players, gaming systems, and television stations. Like many business owners, Dave uses
the Internet to advertise his business to potential customers.

Locating Information on a Network


One of the biggest obstacles to effectively using the Internet is the network’s sheer scope
and size. Most of the early Internet tools required users to master a bewildering array of
terms, acronyms, and commands. Because network users had to be well versed in com-
puters and network technology, Internet use was limited to universities and the govern-
ment. To make the Internet accessible to the general public, it needed to be easier to use.
The solution turned out to be the World Wide Web.
The foundations for the World Wide Web, or the Web for short, were laid in 1989 by
Timothy Berners-Lee and other researchers at the CERN nuclear research facility near
Geneva, Switzerland. They needed an information system that would make it easy for
their researchers to locate and share data on the CERN network with minimal training
and support. To meet this need, they developed a system of hypertext documents that
enabled users to easily navigate from one topic to another. Hypertext is a method of
organization in which data sources are interconnected through a series of links or hyper-
links that users can activate to jump from one piece of information to another. Hypertext
is ideally suited for the Internet because end users do not need to know where a particu-
lar document, information source, or service is located—they need to know only how to
activate the link. The fact that the Internet and the World Wide Web are synonymous in
many users’ minds is a testament to the success of the hypertext approach.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 5

Web Pages and Web Servers


Each document on the World Wide Web is referred to as a Web page and is stored on a
Web server. When you access a Web page, a Web browser retrieves the page from its
Web server and renders it on your computer or other device.
The earliest browsers, known as text-based browsers, were limited to displaying only
text. Today’s browsers are capable of handling text, images, audio, video, and interac-
tive programs. In the early days of the Internet, Web browsing was limited to computers.
Now browsers are installed on devices such as mobile phones, cars, handheld media
devices, and gaming systems, to name only a few. How does a Web page work with so
many combinations of browsers and devices? To understand, you need to look at how
Web pages are created.

Introducing HTML
Web pages are text files written in Hypertext Markup Language (HTML). We’ve already
discussed hypertext, but what is a markup language? A markup language is a language
that describes the content and structure of a document by identifying, or tagging, dif-
ferent elements in the document. For example, this tutorial contains paragraphs, figure
captions, page headings, and so forth; each of these items could be tagged as a distinct
element using a markup language. Thus, HTML is a markup language that supports both
hypertext and the tagging of distinct document elements.

The History of HTML


HTML evolved as the Web itself evolved. Thus, in order to fully appreciate the nuances
of HTML, it’s a good idea to review the language’s history. The first popular markup
language was the Standard Generalized Markup Language (SGML). Introduced in the
1980s, SGML is device- and system-independent, meaning that it can be applied to
almost any type of document stored in almost any format. While powerful, SGML is also
quite complex; for this reason, SGML is limited to those organizations that can afford the
cost and overhead of maintaining complex SGML environments. However, SGML can
also be used to create other markup languages that are tailored to specific tasks and are
simpler to use and maintain. HTML is one of the languages created with SGML.
In the early years after HTML was created, no single organization was responsible for
the language. Web developers were free to define and modify HTML in whatever ways
they thought best. This led to incompatibilities between the various browsers and, as a
result, Web page authors faced the challenge of writing HTML code that would satisfy
different browsers and browser versions.
Ultimately, a group of Web designers and programmers called the World Wide Web
Consortium, or the W3C, created a set of standards or specifications for all browser
manufacturers to follow. The W3C has no enforcement power; but because using a
uniform language is in everyone’s best interest, the W3C’s recommendations are usually
followed, though not always immediately. For more information on the W3C and the
services it offers, see its Web site at www.w3.org.
As HTML evolves, earlier features of the language are often deprecated, or phased
out. While deprecated features might not be part of the current specification for HTML,
that doesn’t mean that you won’t encounter them in your work—indeed, if you are
maintaining older Web sites, you will often need to be able to interpret code from earlier
versions of HTML.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 6 HTML and CSS | Tutorial 1 Getting Started with HTML5

XHTML and the Development of HTML5


Near the end of the 1990s, the W3C released the final specifications for the 4th ver-
sion of HTML, called HTML 4, and began charting a course for the next version. The
path chosen by the W3C was to reformulate HTML in terms of XML. XML (Extensible
Markup Language) is a compact offshoot of SGML and is used to define new markup
languages, known as XML vocabularies. A document based on an XML vocabulary is
forced to obey specific rules for content and structure to avoid being rejected as invalid.
By contrast, HTML allows for a wide variety in syntax between one HTML document
and another. Another important aspect of XML is that several XML vocabularies can be
combined within a single document, making it easier to extend XML into different areas
of application.
The W3C developed an XML vocabulary that was a stricter version of HTML4, known
as XHTML (Extensible Hypertext Markup Language). XHTML was designed to confront
some of the problems associated with the various competing versions of HTML and to
better integrate HTML with other markup languages. Because XHTML was an XML ver-
sion of HTML, most of what Web designers used with HTML could be applied to XHTML
with only a few modifications, and many tools and features associated with XML could
be easily applied to XHTML.
By 2002, the W3C had released the specifications for XHTML 1.1. This version was
intended to be only a minor upgrade on the way to XHTML 2.0, which would contain
a set of XML vocabularies moving HTML into the future with robust support for mul-
timedia, social networking, interactive Web forms, and other features needed by Web
designers. One problem was that XHTML 2.0 would not be backward compatible with
earlier versions of HTML and thus older Web sites could not be easily integrated with the
proposed new standard.
Web designers rebelled at this development. In 2004, Ian Hickson, who was work-
ing for Opera Software at the time, proposed a different path. Hickson’s proposal would
have allowed for the creation of new Web applications while still maintaining backward
compatibility with HTML 4. He argued that HTML was whatever the browser market
determined it to be, and that trying to enforce a new specification that did not accommo-
date the needs and limitations of the market was a fruitless exercise.
Hickson’s proposal was rejected by the W3C and, in response, a new group of Web
designers and browser manufacturers formed the Web Hypertext Application Technology
Working Group (WHATWG) with the mission to develop a rival version to XHTML 2.0,
called HTML5. For several years, it was unclear which specification would represent the
future of the Web; but by 2006, work on XHTML 2.0 had completely stalled. The W3C
issued a new charter for an HTML Working Group to develop HTML5 as the next HTML
specification. Work on XHTML 2.0 was halted in 2009, leaving HTML5 as the de facto
standard for the next generation of HTML.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 7

Figure 1-1 Versions of HTML

Version Date Description


HTML1.0 1989 The first public version of HTML.
HTML 2.0 1995 Added interactive elements including Web forms.
HTML 3.0 1996 A proposed replacement for HTML 2.0 that was never widely
adopted.
HTML 3.2 1997 Included additional support for Web tables and expanded the
options for interactive form elements and a scripting language.
HTML 4.01 1999 Added support for style sheets to give Web designers greater control
over page layout and appearance, and provided support for multi-
media elements such as audio and video. Current browsers support
almost all of HTML 4.01.
XHTML 1.0 2001 A reformulation of HTML 4.01 in the XML language in order to pro-
vide enforceable standards for HTML content and to allow HTML to
interact with other XML languages.
XHTML 1.1 2002 A minor update to XHTML 1.0 that allows for modularity and simpli-
fies writing extensions to the language.
XHTML 2.0 discontinued The follow-up version to XHTML 1.1 designed to fix some of the prob-
lems inherent in HTML 4.01 syntax. Work on this version was discon-
tinued in 2009 due to lack of browser support.
HTML 5.0 In development An update to HTML 4.01 that provides support for a variety of new
features including semantic page elements, column layout, form vali-
dation, offline storage, and enhanced multimedia.
XHTML 5.0 In development A version of HTML 5.0 written under the XML language; unlike
XHTML 2.0, XHTML 5.0 will be backward compatible with XHTML 1.1.

Figure 1-1 summarizes the various versions of HTML that have been developed over
the past 20 years. You may be wondering how on Earth anything can be written with so
many versions of HTML to consider. At the time of this writing, you can write your code
following the standards of HTML 4.01 or XHTML 1.1 and be assured that it will be sup-
ported by all major browsers. Many features of HTML5 are also being rapidly adopted
by the market even as work continues on developing the language. HTML5 is the future,
but the challenges for Web designers today lie in knowing which parts of HTML5 are
supported by which browsers, and in developing strategies for supporting older browsers
even as HTML5 is being implemented.
In this book you’ll use HTML5 code for those features that have already achieved sup-
port among current browsers, but you’ll also learn the standards used for HTML 4.01 and
XHTML 1.1 and practice writing code that will support both current and older browsers.

HTML and Style Sheets


HTML marks the different parts of a document, but it does not indicate how document
content should be displayed by browsers. This is a necessary facet of HTML because a
Web page author has no control over what device will actually view his or her docu-
ment. An end user might be using a large-screen television monitor, a mobile phone, or
even a device that renders Web pages in Braille or in aural speech.
For this reason, the exact appearance of each page element is described in a sepa-
rate document known as a style sheet. Each browser has its own internal style sheet
that specifies the appearance of different HTML elements. For example, content that is
marked as containing the text of an address is rendered by most Web browsers in italic,
while major headings usually appear in large bold-faced fonts.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 8 HTML and CSS | Tutorial 1 Getting Started with HTML5

A Web page author can also create a style sheet that takes precedence over the
internal style sheets of browsers. In addition, an author can create multiple style sheets
for different output devices: one for rendering a page on a computer screen, another for
printed output, and another for rendering the page aurally. In each case, the markup of
the document content is the same, but the presentation is determined by the style sheet.

Tools for Creating HTML Documents


Because HTML documents are simple text files, you can create them using nothing
more than a basic text editor such as Windows Notepad. Other software programs that
enable you to create documents in different formats, such as Microsoft Word or Adobe
Acrobat, include tools to convert their documents into HTML for quick and easy pub-
lishing on the Web.
If you intend to create a large Web site incorporating dozens of Web pages, you
should invest in specialized Web publishing software to manage all of the code and
extended features of your site. Programs such as Adobe Dreamweaver and Microsoft
Expression Web are among the leaders in this field.
Since this book is focused on the HTML language itself and not how to work with dif-
ferent software programs, you’ll need nothing more than a text editor and a Web browser
to complete the assignments that follow.

Entering Elements and Attributes


Now that you’ve had a chance to review a brief history of the Web and the role of HTML
in its development, you are ready to write your first HTML document for the J-Prop Shop.
You’ll start by studying the rules for entering HTML code.

Introducing HTML Tags


An HTML document is composed of elements that represent distinct items in the Web
page, such as a paragraph, the page heading, or even the entire body of the page itself.
Each element is marked within the HTML file by one or more tags. If an element con-
tains text or another element, it is marked using a two-sided tag set in which an opening
tag and a closing tag enclose the element content. The syntax of a two-sided tag set is
<element>content</element>

where element is the name of the element and content is the content of the element.
For example, the following code marks a paragraph using a two-sided tag set:
<p>Welcome to the J-Prop Shop.</p>

In this example, the <p> tag marks the beginning of the paragraph, the text Welcome
to the J-Prop Shop. is the content of the paragraph element, and the </p> tag marks the
end of the paragraph. Elements can also contain other elements. For example, in the
code
<p>Welcome to <em>Dave's Devil Sticks</em>.</p>

the paragraph tags enclose both the text of the paragraph and the tag set
<em> ... </em>, which is used to mark content that should be treated by the browser
as emphasized text. Note that the <em> tag set must be completely enclosed, or nested,
within the <p> tags. It’s improper to have tags overlap as in the following code sample:
<p>Welcome to <em>Dave's Devil Sticks.</p></em>

In this example, the closing </em> tag is placed after the closing </p> tag, which is
improper because one element must be completely contained within another.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 9

An element that does not enclose content is an empty element and it is marked with a
one-sided tag using the syntax
<element />

where element is the name of the element. For example, you can mark a line break
using the br element, which has the following syntax:
<br />

Since empty elements don’t contain content, they’re often employed to send directives
to browsers regarding how a page should be rendered. A browser encountering the br
element would insert a line break, causing the text of the next element in the document
to be placed on a new line.

Specifying an Element Attribute


In addition to content, elements also support attributes that specify the use, the behavior,
and in some cases the appearance of an element. Attribute values don’t appear in the
rendered Web page; rather, they provide information to the browser about the properties
of the element.
To add an attribute to an element, you insert the attribute within the element’s open-
ing tag. For a two-sided tag, the syntax is:
<element attribute1=”value1” attribute2=”value2” ...>
content
</element>

Attributes are added to one-sided tags in the same way:


<element attribute1=”value1” attribute2=”value2” ... />

In these examples, attribute1, attribute2, etc. are the names of attributes associ-
Attributes can be listed in ated with the element, and value1, value2, etc. are the values of those attributes. For
any order, but they must instance, the following code adds the id attribute to a paragraph marked with the p
be separated from one element:
another by a blank space
and enclosed within <p id=”opening”>Welcome to the J-Prop Shop.</p>
single or double
quotation marks.
A browser interpreting this code would recognize that the text Welcome to the J-Prop
Shop. should be treated as a paragraph and given the id value opening.

Adding an Attribute to an Element


REFERENCE

• To add an element attribute, use the format


<element attribute1=”value1”
ƒƒƒƒƒƒƒƒƒattribute2=”value2” ...>content</element>

where attribute1, attribute2, etc. are the names of attributes associated with the
element, and value1, value2, etc. are the values of those attributes.

White Space and HTML


Since an HTML file is a text file, it’s composed of text characters and white space. White
space includes the blank spaces, tabs, and line breaks found within the file. As far as
a browser is concerned, there is no difference between a blank space, a tab, or a line
break. Browsers also ignore consecutive occurrences of white space, collapsing extra

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 10 HTML and CSS | Tutorial 1 Getting Started with HTML5

white space characters into a single blank space. Thus, browsers treat the following para-
graph elements in the same way:
<p>Welcome to the J-Prop Shop.</p>

<p>
Welcome to the J-Prop Shop.
</p>

<p>Welcome
to the J-Prop Shop.</p>

<p>Welcome to the J-Prop Shop.</p>


Because HTML handles white space in this way, you can make your code easier for
others to read by indenting lines and adding extra blank lines to separate one tag from
another in the file.

HTML5 and XHTML Syntax


INSIGHT

The rules that govern how code should be entered are called syntax. The way that HTML
has been implemented by most browsers through the Web’s history has allowed for
minor variations in syntax. One reason for the success of the Web is that HTML has made
it easy for non-programmers to write and edit code without being ensnarled by syntax
violations.
On the other hand, XHTML forces strict syntax on page authors. If an author’s code
does not follow the rules, browsers do not render the page. One advantage of this
approach is that it forces authors to write clear and more concise code; indeed, one of
the driving forces behind the development of XHTML was the desire to clean up some of
the messy and inconsistent code found on the Web.
For example, XHTML requires that all tag names be placed in lowercase letters and
that all attribute values be enclosed within quotation marks. HTML allows either upper-
case or lowercase tag names and does not require attribute values to be quoted. In
addition, XHTML requires that every one-sided tag be entered with a closing slash: for
instance, the br element must be entered as <br /> for XHTML compatibility. Most
browsers, however, accept HTML code in which one-sided tags are entered without clos-
ing slashes; thus, the br element could be entered either as <br> or as <br />.
HTML5 supports the informal standards accepted by most browsers and will continue
to allow for minor variations in syntax. However, it is still good practice to write all code
to be XHTML compliant whenever possible, since it will allow that code to be easily
transferred to XHTML environments if necessary.

Exploring the Structure of an HTML Document


The structure of an HTML document consists of different elements nested within each
other in a hierarchy of elements. The top element in that hierarchy is the html element,
which contains all of the other elements within an HTML file. Directly below the html
element in the hierarchy are the head and body elements. The head element contains
general information about the document—for example, the document’s title, or a list of

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 11

keywords that would aid search engines in directing interested users to the page. The
body element contains all of the content that appears in the rendered Web page. Thus,
the general structure of an HTML file is
<html>
<head>
head content
</head>
<body>
body content
</body>
</html>

where head content and body content are the content you want to place within the
document’s head and body. Note that the body element is always placed after the head
element.

The Document Type Declaration


Prior to the opening <html> tag, many HTML files also include a Document Type
Declaration, or doctype, to indicate the type of markup language used in the document.
The doctype is used by validators, which are programs that examine document code to
ensure that it meets all the syntax requirements of the specified language. All XHTML
files require a doctype because those documents must be validated against a set of
standards.
Most current browsers also use the presence or absence of a doctype to decide which
mode they should use to render a document in a process known as doctype switching. If
a doctype is included, such browsers render the Web page in standards mode, in accor-
dance with the most current specifications of the language. If no doctype is provided,
these browsers render the document in quirks mode based on practices followed in the
1990s. The differences can be striking. Figure 1-2 shows an example of two documents
rendered by Internet Explorer under standards mode and quirks mode. The only differ-
ence in the code between these two documents is the presence or absence of a doctype,
but the browser renders the two documents very differently.

Figure 1-2 A Web page rendered in standards mode and quirks mode

Standards mode Quirks mode

Different HTML versions have different doctypes. The doctype for HTML 4.01 is:
<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01/EN”
ƒƒ“http://www.w3.org/TR/html4/strict.dtd”>

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 12 HTML and CSS | Tutorial 1 Getting Started with HTML5

The doctype for XHTML is:


<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN”
“http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>

Finally, the doctype for HTML5 is much simpler than what was required for
HTML 4.01 or XHTML:
<!DOCTYPE html>

HTML5 documents should always be opened in standards mode because they are
Unless you are work- based on the latest specifications for the HTML language.
ing with a legacy page You can learn more about standards mode and quirks mode by searching the Web for
that absolutely needs to examples of the differences between the two modes.
be compatible with old
browsers from the 1990s,
you should always Creating the Initial Document
include a doctype and
put your browser in Now that you’ve seen the basic structure of an HTML document, you are ready to begin
standards mode. creating the sample Web page for Dave’s Web site.

Creating the Basic Structure of an HTML Document


REFERENCE

Enter the HTML tags


doctype
<html>
<head>
head content
</head>
<body>
body content
</body>
</html>

where doctype is the Document Type Declaration, and head content and body
content are the content of the document’s head and body.

You can start creating Dave’s Web page using a basic editor such as Windows
Notepad. Since Dave wants his document to be based on HTML5, you’ll use the HTML5
doctype in your file.

To create the basic structure of an HTML document:


◗ 1. Start your text editor, opening a blank text document.
Trouble? If you don’t know how to start or use your text editor, ask your instruc-
tor or technical support person for help. Note that some editors do not save files
in text file format by default, so check your editor’s documentation to ensure that
you are creating a basic text document.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 13

Make sure you include ◗ 2. Type the following lines of code in your document. Press the Enter key after each
the exclamation point (!) line. Press the Enter key twice for a blank line between lines of code. See Figure 1-3.
within the doctype; oth-
erwise, browsers will not <!DOCTYPE html>
recognize the doctype. <html>

<head>
</head>

<body>
</body>

</html>

Figure 1-3 Basic structure of an HTML file

doctype for HTML5


doctype indicates the documents
type of document
head section contains
opening html tag information about the
document

body section contains


content to be displayed
closing html tag by Web browsers

◗ 3. Save the file as jprop.htm in the tutorial.01\tutorial folder included with your
To make it easier to link Data Files.
to your Web pages, follow
Trouble? If you are using the Windows Notepad text editor to create your HTML
the Internet convention
of naming HTML files file, make sure you don’t save the file with the extension .txt, which is the default
and folders using only file extension for Notepad. Instead, save the file with the file extension .htm or
lowercase letters with no .html. Using the incorrect file extension might make the file unreadable to Web
spaces. browsers, which require file extensions of .htm or .html.

Now that you’ve entered the basic structure of your HTML file, you can start entering
the content of the head element.

Marking the Head Element


In general, the head element is where you provide browsers with information about your
document. This can include the page’s title, the location of any style sheets used with the
document, the location of any programs that browsers should run when they load the
page, and information for use by search engines to aid users in locating the Web site.

Defining the Page Title


The first element you’ll add to the head of Dave’s document is the title element, which
has the syntax
<title>document title</title>

where document title is the text of the document title. The document title is not dis-
played within the page, but is usually displayed in a browser’s title bar or on a browser

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 14 HTML and CSS | Tutorial 1 Getting Started with HTML5

tab. The document title is also used by search engines like Google or Yahoo! when com-
piling an index of search results.

Indent your markup tags


and insert extra blank
spaces as shown in this To add a title to your Web page:
book to make your code
easier to read. These
◗ 1. Click at the end of the opening <head> tag, and then press the Enter key to insert
indentations and spaces a new line in your text editor.
do not affect how the page
is rendered by browsers.
◗ 2. Press the Spacebar several times to indent the new line of code, and then type
<title>The J-Prop Shop</title> as shown in Figure 1-4.

Figure 1-4 Specifying the page title

text will appear in


browser title bar
or on browser tab

Adding Comments
As you write your HTML file, you can add notes or comments about your code. These
comments might include the name of the document’s author and the date the document
was created. Such notes are not intended to be displayed by browsers, but are instead
used to help explain your code to yourself and others. To add notes or comments, insert
a comment tag using the syntax
<!-- comment -->

where comment is the text of the comment or note. For example, the following code
inserts a comment describing the page you’ll create for Dave’s business:
<!-- Sample page for the J-Prop Shop -->

A comment can also be spread out over several lines as follows:


<!-- Sample page for the J-Prop Shop.
Created by Dave Vinet -->

Because they are ignored by the browser, comments can be added anywhere within
the html element.

Adding an HTML Comment


REFERENCE

To insert an HTML comment anywhere within your document, enter


<!-- comment -->

where comment is the text of the HTML comment.

You’ll add a comment to the jprop.htm file, identifying the author and purpose of this
document.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 15

To add a comment to the document head:


◗ 1. Click at the end of the opening <head> tag, and then press the Enter key to insert
a new line in your text editor directly above the opening <title> tag.
◗ 2. Type the following lines of code as shown in Figure 1-5:
<!-- The J-Prop Shop Sample Page
Author: your name
Date: the date
-->

where your name is your name and the date is the current date.

Figure 1-5 Adding comments to the HTML file

multi-line comment
describing the
document

Displaying an HTML File


As you continue modifying the HTML code, you should occasionally view the page with
your Web browser to verify that you have not introduced any errors. You might even
want to view the results using different browsers to check for compatibility. In this book,
Web pages are displayed using the Windows Internet Explorer 9 browser. Be aware that
if you are using a different browser or a different operating system, you might see slight
differences in the layout and appearance of the page.

To view Dave’s Web page:


◗ 1. Save your changes to the jprop.htm file.
◗ 2. Start your Web browser. You do not need to be connected to the Internet to view
local files stored on your computer.
Trouble? If you start your browser and are not connected to the Internet, you
might get a warning message. Click the OK button to ignore the message and
continue.
◗ 3. After your browser loads its home page, open the jprop.htm file from the
tutorial.01\tutorial folder.
Trouble? If you’re not sure how to open a local file with your browser, check for
an Open or Open File command under the browser’s File menu. If you are still
having problems accessing the jprop.htm file, talk to your instructor or technical
resource person.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 16 HTML and CSS | Tutorial 1 Getting Started with HTML5

Your browser displays the Web page shown in Figure 1-6. Note that in this case,
the page title appears in the browser tab; in other cases, it will appear in the
browser’s title bar. The page itself is empty because you have not yet added any
content to the body element.

Figure 1-6 Viewing the initial HTML file in a Web browser

document title
appears in the
browser tab

no content appears
in the page body

Converting an HTML Document into XHTML


INSIGHT

There is considerable overlap between HTML and XHTML. You can quickly change
an HTML document into an XHTML document just by altering the first three lines of
code. To convert an HTML file into an XHTML file, replace the doctype and the opening
<html> tag with the following:
<?xml version=”1.0” encoding=”UTF-8” standalone=”no” ?>
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN”
“http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”>

Since XHTML is an XML vocabulary, the first line notifies browsers that the document
is an XML file. The version number—1.0—tells the browser that the file is written in
XML 1.0. The second line provides the doctype for an XHTML document written under
a strict interpretation of XHTML syntax. The third line of the file contains the opening
<html> tag. In XHTML, the <html> tag must include what is known as a namespace
declaration indicating that any markup tags in the document should, by default, be
considered part of the XHTML language. Because XML documents can contain a mixture
of several different vocabularies, the namespace declaration is necessary to specify the
default language of the document. With these three lines in place, browsers will recog-
nize the file as an XHTML document.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 17

Defining the Structure of the Page Body


Now that you’ve marked the document head and inserted a page title, you’ll turn to the
contents of the body of the Web page. It’s always a good idea to plan your Web page
before you start coding it. You can do this by drawing a sketch or by creating a sample
document within a word processor. Your preparatory work can weed out textual errors
or point to potential problems in your page layout. In this case, Dave has already drawn
up a flyer that he’s passed out at juggling and circus conventions. Figure 1-7 shows the
handout, which provides information about Dave’s company and his products.

Figure 1-7 Dave’s flyer

Dave’s flyer contains several elements that are common to many Web pages, as
shown in Figure 1-8. A header displays the company’s logo and a footer displays contact
information for the J-Prop Shop. The main section, which describes Dave’s business,
includes several subsections, also known as articles. A second section that appears as a
sidebar displays quotes from some J-Prop customers.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 18 HTML and CSS | Tutorial 1 Getting Started with HTML5

Figure 1-8 Structure of Dave’s Web page

header

article

section

article

article
aside footer

Working with HTML5 Structural Elements


Each of these parts of Dave’s document can be marked using HTML5 structural elements,
which are the elements that define the major sections of a Web page. Figure 1-9 describes
some of these elements.

Figure 1-9 HTML5 structural elements

Structural Element Description


article A subsection covering a single topic
aside Content containing tangential or side issues to the main topic of the page
footer Content placed at the bottom of the page
header Content placed at the top of the page
nav A navigation list of hypertext links
section A major topical area in the page

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 19

For example, to mark the header of your Web page, you would enter a header ele-
ment within the page body, using the syntax
<header>
header content
</header>

where header content is the page content that you want displayed within the page
header. One of the reasons we want to define these structural elements is that we can
write styles for them and define the layout of the Web page content.

Marking Structural Elements in HTML5


REFERENCE

• To mark the page header, use the header element.


• To mark the page footer, use the footer element.
• To mark a main section of page content, use the section element.
• To mark a sidebar, use the aside element.
• To mark an article, use the article element.

Based on Dave’s sample document shown in Figure 1-8, you’ll add the header,
section, aside, and footer structural elements to your HTML file.

To insert the HTML5 structural elements:


◗ 1. Return to the jprop.htm file in your text editor.
◗ 2. Within the body element, insert the following tags as shown in Figure 1-10:
<header>
</header>

<section>
</section>

<aside>
</aside>

<footer>
</footer>

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 20 HTML and CSS | Tutorial 1 Getting Started with HTML5

Figure 1-10 Inserting structural elements

marks a section
within the page

marks the page header


marks the page
footer

marks a sidebar
within the page

◗ 3. Save your changes to the file.

Structural elements can also be nested within one another. In the structure of Dave’s
page from Figure 1-8, notice that the section element contains three article elements. Add
this content to your HTML file by nesting three article elements within the section
element.

To add three article elements:


◗ 1. Within the section element, insert the following code as shown in Figure 1-11:
<article>
</article>

<article>
</article>

<article>
</article>

Figure 1-11 Inserting nested elements

article elements

◗ 2. Save your changes to the file.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 21

Marking a Section with the div Element


The structural elements are part of the current specifications for HTML5, but they are
not part of HTML 4.01 or XHTML. Pages written to those languages instead use the div
element to identify different page divisions. The syntax of the div element is
<div id=”id”>
content
</div>

where id is a unique name assigned to the division and content is page content con-
tained within the division. While not required, the id attribute is useful to distinguish
one div element from another. This becomes particularly important if you apply different
styles to different page divisions.
Figure 1-12 shows how the same page layout marked up using structural elements
under HTML5 would be marked up in HTML 4.01 using the div element.

Figure 1-12 Structural elements in HTML5 and HTML 4.01

<header>
HTML5

<nav> <section> <aside>

<article>

<footer>

<div id="header">
HTML 4.01

<div id="nav"> <div id="section"> <div


id="aside">

<div id="article">

<div id="footer">

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
HTML 22 HTML and CSS | Tutorial 1 Getting Started with HTML5

You can use either HTML5’s structural elements or HTML 4.01’s div elements to
identify the major sections of your document. The HTML5 approach is preferred because
it represents the future standard of the Web, and structural elements are more descriptive
than the generic div element. One problem with the div element is that there are no
rules for id names. One Web designer might identify the page heading with the id name
header while another designer might use heading or top. This makes it harder for Web
search engines to identify the main topics of interest in each Web page.

Written Communication: Writing Effective HTML Code


PROSKILLS

Part of writing good HTML code is being aware of the requirements of various browsers
and devices, as well as understanding the different versions of the language. Here are a few
guidelines for writing good HTML code:
• Become well versed in the history of HTML and the various versions of HTML and XHTML.
Unlike other languages, HTML’s history does impact how you write your code.
• Know your market. Do you have to support older browsers, or have your clients standard-
ized on one particular browser or browser version? Will your Web pages be viewed on a
single device such as a computer, or do you have to support a variety of devices?
• Test your code on several different browsers and browser versions. Don’t assume that if
your page works in one browser it will work in other browsers, or even in earlier versions
of the same browser. Also check on the speed of the connection. A large file that per-
forms well with a high-speed connection might be unusable with a dial-up connection.
• Read the documentation on the different versions of HTML and XHTML at the W3C Web
site and keep up to date with the latest developments in the language.
In general, any HTML code that you write should be compatible with the current versions
of the following browsers: Internet Explorer (Windows), Firefox (Windows and Macintosh),
Safari (Windows and Macintosh), Chrome (Windows and Macintosh), and Opera (Windows
and Macintosh). In addition, you should also view your pages on a variety of devices includ-
ing laptops, mobile phones, and tablets. To effectively communicate with customers and
users, you need to make sure your Web site is always readable.

At this point, you’ve created the basic framework of Dave’s Web page. In the next ses-
sion, you’ll insert the page content and learn how to apply a visual style to that content
to create a nicely formatted Web page. If you want to take a break before starting the
next session, you can close any open files or applications.

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Tutorial 1 Getting Started with HTML5 | HTML and CSS HTML 23

Session 1.1 Quick Check

REVIEW
1. What is a markup language?
2. What is XHTML? How does XHTML differ from HTML?
3. What is the W3C? What is the WHATWG?
4. What is a doctype? What are two uses of the doctype?
5. What is incorrect about the syntax of the following code?
<p>Welcome to the <em>J-Prop Shop</p></em>

6. What is white space? How does HTML treat consecutive occurrences of


white space?
7. What structural element would you use to mark a sidebar?
8. What structural element would you use to mark the page footer?

Copyright 2013 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part.
Other documents randomly have
different content
The Project Gutenberg eBook of The Natural
History of Pliny, Volume 2 (of 6)
This ebook is for the use of anyone anywhere in the United
States and most other parts of the world at no cost and with
almost no restrictions whatsoever. You may copy it, give it away
or re-use it under the terms of the Project Gutenberg License
included with this ebook or online at www.gutenberg.org. If you
are not located in the United States, you will have to check the
laws of the country where you are located before using this
eBook.

Title: The Natural History of Pliny, Volume 2 (of 6)

Author: the Elder Pliny

Translator: John Bostock


Henry T. Riley

Release date: September 3, 2019 [eBook #60230]


Most recently updated: October 17, 2024

Language: English

Credits: Produced by Turgut Dincer, Tony Browne, Stephen


Rowland
and the Online Distributed Proofreading Team at
http://www.pgdp.net (This file was produced from
images
generously made available by The Internet Archive)

*** START OF THE PROJECT GUTENBERG EBOOK THE NATURAL


HISTORY OF PLINY, VOLUME 2 (OF 6) ***
THE
NATURAL HISTORY
OF

PLINY.
TRANSLATED,

WITH COPIOUS NOTES AND ILLUSTRATIONS


BY THE LATE

JOHN BOSTOCK, M.D., F.R.S.,

AND

H. T. RILEY, Esq., B.A.,


LATE SCHOLAR OF CLARE HALL, CAMBRIDGE.

VOL. II.

LONDON:
HENRY G. BOHN, YORK STREET, COVENT GARDEN.
MDCCCLV.
J. BILLING,
PRINTER AND STEREOTYPER,
WOKING, SURREY.
CONTENTS.

OF THE SECOND VOLUME.

BOOK VI.

AN ACCOUNT OF COUNTRIES, NATIONS, SEAS, TOWNS, HAVENS,


MOUNTAINS, RIVERS, DISTANCES, AND PEOPLES WHO NOW EXIST,
OR FORMERLY EXISTED.
Chap. Page
1. The Euxine and the Maryandini 1
2. Paphlagonia 3
3. Cappadocia 6
4. The region of Themiscyra, and the nations therein 8
5. The region of Colica, the nations of the Achæi, and other
nations in the same parts 11
6. The Cimmerian Bosporus 13
7. Lake Mæotis and the adjoining nations 14
8. The situation of Cappadocia 16
9. The Lesser and the Greater Armenia 17
10. The rivers Cyrus and Araxes 18
11. Albania, Iberia, and the adjoining nations 20
12. The passes of the Caucasus 21
13. The islands of the Euxine 22
14. Nations in the vicinity of the Scythian Ocean 23
15. The Caspian and Hyrcanian Sea 24
16. Adiabene 27
17. Media and the Caspian Gates 28
18. Nations situate around the Hyrcanian Sea 30
19. The nations of Scythia and the countries on the Eastern
Ocean 33
20. The Seres 35
21. The nations of India 38
22. The Ganges 43
23. The Indus 46
24. Taprobane 51
25. The Ariani and the adjoining nations 56
26. Voyages to India 60
27. Carmania 66
28. The Persian and the Arabian Gulfs ib.
29. The Parthian Empire 68
30. Mesopotamia 70
31. The Tigris 75
32. Arabia 82
33. The Gulfs of the Red Sea 91
34. Troglodytice 93
35. Æthiopia 97
36. Islands of the Æthiopian Sea 105
37. The Fortunate Islands 107
38. The comparative distances of places on the face of the
earth 108
39. Division of the earth into parallels and shadows of equal
length 110

BOOK VII.

MAN, HIS BIRTH, HIS ORGANIZATION, AND THE INVENTION OF


THE ARTS.
1. Man 117
2. The wonderful forms of different nations 122
3. Marvellous births 135
4. The generation of man; the unusual duration of
pregnancy; instances of it from seven to twelve
months 139
5. Indications of the sex of the child during the pregnancy
of the mother 141
6. Monstrous births 142
7. Of those who have been cut out of the womb 143
8. Who were called Vopisci 144
9. The conception and generation of man ib.
10. Striking instances of resemblance 145
11. What men are suited for generation. Instances of very
numerous offspring 148
12. At what age generation ceases 150
13. Remarkable circumstances connected with the menstrual
discharge ib.
14. The theory of generation 153
15. Some account of the teeth, and some facts concerning
infants ib.
16. Examples of unusual size 155
17. Children remarkable for their precocity 158
18. Some remarkable properties of the body ib.
19. Instances of extraordinary strength 160
20. Instances of remarkable agility 161
21. Instances of acuteness of sight 162
22. Instances of remarkable acuteness of hearing 163
23. Instances of endurance of pain 164
24. Memory ib.
25. Vigour of mind 166
26. Clemency and greatness of mind ib.
27. Heroic exploits 167
28. Union in the same person of three of the highest
qualities with the greatest purity 169
29. Instances of extreme courage 170
30. Men of remarkable genius 173
31. Men who have been remarkable for wisdom 174
32. Precepts the most useful in life 178
33. Divination 179
34. The man who was pronounced to be the most excellent ib.
35. The most chaste matrons 180
36. Instances of the highest degree of affection ib.
37. Names of men who have excelled in the arts, astrology,
grammar, and medicine 182
38. Geometry and architecture 183
39. Painting; engraving on bronze, marble, and ivory;
carving 184
40. Slaves for which a high price has been given 185
41. Supreme happiness 186
42. Rare instances of good fortune continuing in the same
family 187
43. Remarkable example of vicissitudes 189
44. Remarkable examples of honours ib.
45. Ten very fortunate circumstances which have happened
to the same person 191
46. The misfortunes of Augustus 195
47. Men whom the gods have pronounced to be the most
happy 199
48. The man whom the gods ordered to be worshipped
during his life-time; a remarkable flash of lightning ib.
49. The greatest length of life 200
50. The variety of destinies at the birth of man 203
51. Various instances of diseases 206
52. Death 208
53. Persons who have come to life again after being laid out
for burial 210
54. Instances of sudden death 213
55. Burial 217
56. The Manes, or departed spirits of the soul 218
57. The inventors of various things 219
58. The things about which mankind first of all agreed. The
ancient letters 236
59. When barbers were first employed ib.
60. When the first time-pieces were made 237

BOOK VIII.

THE NATURE OF THE TERRESTRIAL ANIMALS.


1. Elephants; their capacity 244
2. When elephants were first put into harness 245
3. The docility of the elephant 246
4. Wonderful things which have been done by the elephant 247
5. The instinct of wild animals in perceiving danger 248
6. When elephants were first seen in Italy 251
7. The combats of elephants 252
8. The way in which elephants are caught 255
9. The method by which they are tamed 256
10. The birth of the elephant, and other particulars
respecting it 257
11. In what countries the elephant is found; the antipathy of
the elephant and the dragon 259
12. The sagacity of these animals 260
13. Dragons 261
14. Serpents of remarkable size ib.
15. The animals of Scythia; the bison 262
16. The animals of the north; the elk, the achlis, and the
bonasus 263
17. Lions; how they are produced 264
18. The different species of lions 266
19. The peculiar character of the lion 267
20. Who it was that first introduced combats of lions at
Rome, and who has brought together the greatest
number of lions for that purpose 269
21. Wonderful feats performed by lions 270
22. A man recognized and saved by a dragon 273
23. Panthers 274
24. The decree of the Senate, and laws respecting African
animals; who first brought them to Rome, and who
brought the greatest number of them ib.
25. Tigers: when first seen at Rome; their nature 275
26. Camels; the different kinds 276
27. The cameleopard; when it was first seen at Rome 277
28. The chama, and the cepus ib.
29. The rhinoceros 278
30. The lynx, the sphinx, the crocotta, and the monkey ib.
31. The terrestrial animals of India 280
32. The animals of Æthiopia; a wild beast which kills with its
eye 281
33. The serpents called basilisks 282
34. Wolves; the origin of the story of Versipellis ib.
35. Different kinds of serpents 284
36. The ichneumon 287
37. The crocodile ib.
38. The scincus 288
39. The hippopotamus 290
40. Who first exhibited the hippopotamus and the crocodile
at Rome ib.
41. The medicinal remedies which have been borrowed from
animals 291
42. Prognostics of danger derived from animals 294
43. Nations that have been exterminated by animals 295
44. The hyæna 296
45. The crocotta; the mantichora ib.
46. Wild asses 297
47. Beavers; amphibious animals; otters ib.
48. Bramble-frogs 298
49. The sea-calf; beavers; lizards ib.
50. Stags 299
51. The chameleon 302
52. Other animals which change colour; the tarandus, the
lycaon, and the thos 304
53. The porcupine 305
54. Bears and their cubs ib.
55. The mice of Pontus and of the Alps 308
56. Hedgehogs ib.
57. The leontophonus, and the lynx 310
58. Badgers and squirrels ib.
59. Vipers and snails 311
60. Lizards 312
61. The qualities of the dog; examples of its attachment to
its master; nations which have kept dogs for the
purposes of war ib.
62. The generation of the dog 316
63. Remedies against canine madness ib.
64. The nature of the horse 317
65. The disposition of the horse; remarkable facts
concerning chariot horses 319
66. The generation of the horse 320
67. Mares impregnated by the wind 322
68. The ass; its generation ib.
69. The nature of mules, and of other beasts of burden 324
70. Oxen; their generation 326
71. The Egyptian Apis 330
72. Sheep, and their propagation 331
73. The different kinds of wool, and their colours 333
74. Different kinds of cloth 336
75. The different shapes of sheep; the musmon 338
76. Goats, and their propagation 339
77. The hog 342
78. The wild boar; who was the first to establish parks for
wild animals 344
79. Animals in a half-wild state 346
80. Apes 347
81. The different species of hares 348
82. Animals which are tamed in part only 350
83. Places in which certain animals are not to be found 352
84. Animals which injure strangers only, as also animals
which injure the natives of the country only, and
where they are found 353

BOOK IX.

THE NATURAL HISTORY OF FISHES.


1. Why the largest animals are found in the sea 358
2. The sea monsters of the Indian Ocean 359
3. The largest animals that are found in each ocean 361
4. The forms of the Tritons and Nereids. The forms of sea-
elephants 362
5. The balæna and the orca 365
6. Whether fishes respire, and whether they sleep 367
7. Dolphins 369
8. Human beings who have been beloved by dolphins 371
9. Places where dolphins help men to fish 374
10. Other wonderful things relating to dolphins 376
11. The tursio 377
12. Turtles; the various kinds of turtles, and how they are
caught ib.
13. Who first invented the art of cutting tortoise-shell 379
14. Distribution of aquatic animals into various species ib.
15. Those which are covered with hair, or have none, and
how they bring forth. Sea-calves, or phocæ 380
16. How many kinds of fish there are 381
17. Which of the fishes are of the largest size 382
18. Tunnies, cordyla, and pelamides, and the various parts of
them that are salted. Melandrya, apolecti, and cybia 385
19. The aurias and the scomber 386
20. Fishes which are never found in the Euxine; those which
enter it and return 387
21. Why fishes leap above the surface of the water 390
22. That auguries are derived from fishes 391
23. What kinds of fishes have no males ib.
24. Fishes which have a stone in the head; those which keep
themselves concealed during winter; and those which
are not taken in winter, except upon stated days 392
25. Fishes which conceal themselves during the summer;
those which are influenced by the stars 396
26. The mullet 397
27. The acipenser 398
28. The lupus, the asellus 399
29. The scarus, the mustela 400
30. The various kinds of mullets, and the sargus that attends
them 401
31. Enormous prices of some fish 403
32. That the same kinds are not everywhere equally
esteemed 404
33. Gills and scales 405
34. Fishes which have a voice.—Fishes without gills 406
35. Fishes which come on land; the proper time for catching
fish ib.
36. Classification of fishes, according to the shape of the
body 407
37. The fins of fish, and their mode of swimming 408
38. Eels 409
39. The murena ib.
40. Various kinds of flat fish 411
41. The echeneis, and its uses in enchantments 412
42. Fishes which change their colour 414
43. Fishes which fly above the water—the sea-swallow—the
fish that shines in the night—the horned fish—the sea-
dragon 415
44. Fishes which have no blood.—Fishes known as soft fish 416
45. The sæpia, the loligo, the scallop 417
46. The polypus ib.
47. The nautilus, or sailing polypus 419
48. The various kinds of polypi; their shrewdness ib.
49. The sailing nauplius 422
50. Sea-animals which are enclosed with a crust; the cray-
fish 423
51. The various kinds of crabs; the pinnotheres, the sea
urchin, cockles, and scallops 424
52. Various kinds of shell-fish 428
53. What numerous appliances of luxury are found in the
sea 429
54. Pearls; how they are produced, and where 430
55. How pearls are found 433
56. The various kinds of pearls 434
57. Remarkable facts connected with pearls—their nature 436
58. Instances of the use of pearls 437
59. How pearls first came into use at Rome 440
60. The nature of the murex and the purple 441
61. The different kinds of purples 443
62. How wools are dyed with the juices of the purple 445
63. When purple was first used at Rome; when the laticlave
vestment and the prætexta were first worn 447
64. Fabrics called conchyliated 448
65. The amethyst, the Tyrian, the hysginian, and the crimson
tints 449
66. The pinna, and the pinnotheres 450
67. The sensitiveness of water-animals; the torpedo, the
pastinaca, the scolopendra, the glanis, and the ram-
fish 451
68. Bodies which have a third nature, that of the animal and
vegetable combined—the sea-nettle 453
69. Sponges; the various kinds of them, and where they are
produced: proofs that they are gifted with life by
nature 454
70. Dog-fish 456
71. Fishes which are enclosed in a stony shell—sea-animals
which have no sensation—other animals which live in
the mud 458
72. Venomous sea-animals 459
73. The maladies of fishes 460
74. The generation of fishes 461
75. Fishes which are both oviparous and viviparous 465
76. Fishes the belly of which opens in spawning, and then
closes again 466
77. Fishes which have a womb; those which impregnate
themselves ib.
78. The longest lives known amongst fishes 467
79. The first person that formed artificial oyster-beds ib.
80. Who was the first inventor of preserves for other fish 469
81. Who invented preserves for murenæ ib.
82. Who invented preserves for sea-snails 470
83. Land-fishes 471
84. The mice of the Nile 472
85. How the fish called the anthias is taken 473
86. Sea-stars 474
87. The marvellous properties of the dactylus 475
88. The antipathies and sympathies that exist between
aquatic animals ib.

BOOK X.

THE NATURAL HISTORY OF BIRDS.


1. The ostrich 478
2. The phœnix 479
3. The different kinds of eagles 481
4. The natural characteristics of the eagle 484
5. When the eagle was first used as the standard of the
Roman legions 485
6. An eagle which precipitated itself on the funeral pile of a
girl 486
7. The vulture ib.
8. The birds called sangualis and immusulus 487
9. Hawks. The buteo ib.
10. In what places hawks and men pursue the chase in
company with each other 488
11. The only bird that is killed by those of its own kind.—A
bird that lays only one egg 489
12. The kite 490
13. The classification of birds ib.
14. Crows. Birds of ill omen. At what seasons they are not
inauspicious ib.
15. The raven 491
16. The horned owl 492
17. Birds, the race of which is extinct, or of which all
knowledge has been lost ib.
18. Birds which are born with the tail first 493
19. The owlet 494
20. The wood-pecker of Mars ib.
21. Birds which have hooked talons 495
22. The peacock ib.
23. Who was the first to kill the peacock for food. Who first
taught the art of cramming them 496
24. The dunghill cock ib.
25. How cocks are castrated. A cock that once spoke 498
26. The goose ib.
27. Who first taught us to use the liver of the goose for food 499
28. The Commagenian medicament 500
29. The chenalopex, the cheneros, the tetrao, and the otis ib.
30. Cranes 501
31. Storks 502
32. Swans ib.
33. Foreign birds which visit us; the quail, the glottis, the
cychramus, and the otus 503
34. Swallows 505
35. Birds which take their departure from us, and whither
they go; the thrush, the blackbird, and the starling—
birds which lose their feathers during their retirement
—the turtle-dove and the ring-dove—the flight of
starlings and swallows ib.
36. Birds which remain with us throughout the year; birds
which remain with us only six or three months;
whitwalls and hoopoes 506
37. The Memnonides ib.
38. The Meleagrides 507
39. The Seleucides ib.
40. The ibis ib.
41. Places in which certain birds are never found ib.
42. The various kinds of birds which afford omens by their
note. Birds which change their colour and their voice 509
43. The nightingale ib.
44. The melancoryphus, the erithacus, and the phœnicurus 511
45. The œnanthe, the chlorion, the blackbird, and the ibis ib.
46. The times of incubation of birds 512
47. The halcyones: the halcyon days that are favourable to
navigation ib.
48. Other kinds of aquatic birds 513
49. The instinctive cleverness displayed by birds in the
construction of their nests. The wonderful works of the
swallow. The bank-swallow ib.
50. The acanthyllis and other birds 515
51. The merops—partridges 516
52. Pigeons 517
53. Wonderful things done by them; prices at which they
have been sold 519
54. Different modes of flight and progression in birds 520
55. The birds called apodes or cypseli 521
56. Respecting the food of birds—the caprimulgus, the
platea ib.
57. The instincts of birds—the carduelis, the taurus, the
anthus 522
58. Birds which speak—the parrot ib.
59. The pie which feeds on acorns 523
60. A sedition that arose among the Roman people, in
consequence of a raven speaking 524
61. The birds of Diomedes 526
62. Animals that can learn nothing ib.
63. The mode of drinking with birds. The porphyrio 527
64. The hæmatopous ib.
65. The food of birds ib.
66. The pelican ib.
67. Foreign birds: the phalerides, the pheasant, and the
numidicæ 528
68. The phœnicopterus, the attagen, the phalacrocorax, the
pyrrhocorax, and the lagopus ib.
69. The new birds. The vipio 529
70. Fabulous birds 530
71. Who first invented the art of cramming poultry: why the
first Censors forbade this practice 531
72. Who first invented aviaries. The dish of Æsopus ib.
73. The generation of birds: other oviparous animals 532
74. The various kinds of eggs, and their nature ib.
75. Defects in brood-hens, and their remedies 535
76. An augury derived from eggs by an empress ib.
77. The best kinds of fowls 536
78. The diseases of fowls, and their remedies 537
79. When birds lay, and how many eggs. The various kinds
of herons ib.
80. What eggs are called hypenemia, and what cynosura.
How eggs are best kept 539
81. The only winged animal that is viviparous, and nurtures
its young with its milk 540
82. Terrestrial animals that are oviparous. Various kinds of
serpents ib.
83. Generation of all kinds of terrestrial animals ib.
84. The position of animals in the uterus 544
85. Animals whose origin is still unknown ib.
86. Salamanders 545
87. Animals which are born of beings that have not been
born themselves—animals which are born themselves,
but are not reproductive—animals which are of neither
sex 546
88. The senses of animals—that all have the senses of touch
and taste—those which are more remarkable for their
sight, smell, or hearing—moles—whether oysters have
the sense of hearing ib.
89. Which fishes have the best hearing 547
90. Which fishes have the finest sense of smell. ib.
91. Diversities in the feeding of animals 548
92. Animals which live on poisons ib.
93. Animals which live on earth—animals which will not die
of hunger or thirst 549
94. Diversities in the drinking of animals 550
95. Antipathies of animals. Proofs that they are sensible of
friendship and other affections ib.
96. Instances of affection shown by serpents 552
97. The sleep of animals ib.
98. What animals are subject to dreams 553
NATURAL HISTORY OF PLINY.
BOOK VI.

AN ACCOUNT OF COUNTRIES, NATIONS, SEAS, TOWNS, HAVENS,


MOUNTAINS, RIVERS, DISTANCES, AND PEOPLES WHO NOW EXIST,
OR FORMERLY EXISTED.

CHAP. 1. (1.)—THE EUXINE AND THE MARYANDINI.

THE Euxine1 Sea, which in former times had the name of Axenus,2
from the savage and inhospitable character of the nations living on
its borders, by a peculiar whim of nature, which is continually giving
way before the greedy inroads of the sea, lies between Europe and
Asia. It was not enough for the ocean to have surrounded the earth,
and then deprived us of a considerable portion of it, thus rendering
still greater its uninhabitable proportion; it was not enough for it to
have forced a passage through the mountains, to have torn away
Calpe from Africa, and to have swallowed up a much larger space
than it left untouched; it was not enough for it to have poured its
tide into the Propontis through the Hellespont, after swallowing up
still more of the dry land—for beyond the Bosporus, as well, it opens
with its insatiate appetite upon another space of immense extent,
until the Mæotian lakes3 unite their ravening waters with it as it
ranges far and wide.
That all this has taken place in spite, as it were, of the earth, is
manifested by the existence of so many straits and such numbers of
narrow passages formed against the will of nature—that of the
Hellespont,4 being only eight hundred and seventy-five paces in
width, while at the two Bospori5 the passage across may be effected
by oxen6 swimming, a fact from which they have both derived their
name. And then besides,7 although they are thus severed, there are
certain points on which these coasts stand in the relation of
brotherhood towards each other—the singing of birds and the
barking of dogs on the one side can be heard on the other, and an
intercourse can be maintained between these two worlds by the
medium even of the human voice,8 if the winds should not happen
to carry away the sound thereof.
The length of the borders of the Euxine from the Bosporus to the
Lake Mæotis has been reckoned by some writers at fourteen
hundred and thirty-eight miles; Eratosthenes, however, says that it is
one hundred less. According to Agrippa, the distance from
Chalcedon to the Phasis is one thousand miles, and from that river
to the Cimmerian Bosporus three hundred and sixty. We will here
give in a general form the distances as they have been ascertained
in our own times; for our arms have even penetrated to the very
mouth of the Cimmerian Straits.
After passing the mouth of the Bosporus we come to the river
Rhebas,9 by some writers called the Rhesus. We next come to
Psillis,10 the port of Calpas,11 and the Sagaris,12 a famous river,
which rises in Phrygia and receives the waters of other rivers of vast
magnitude, among which are the Tembrogius13 and the Gallus,14 the
last of which is by many called the Sangarius. After leaving the
Sagaris the Gulf of the Mariandyni15 begins, and we come to the
town of Heraclea,16 on the river Lycus;17 this place is distant from
the mouth of the Euxine two hundred miles. The sea-port of Acone18
comes next, which has a fearful notoriety for its aconite or wolf’s-
bane, a deadly poison, and then the cavern of Acherusia,19 the
rivers Pædopides, Callichorus, and Sonautes, the town of Tium,20
distant from Heraclea thirty-eight miles, and the river Billis.
CHAP. 2. (2.)—PAPHLAGONIA.

Beyond this river begins the nation of Paphlagonia,21 by some


writers called Pylæmenia;22 it is closed in behind by the country of
Galatia. In it are Mastya,23 a town founded by the Milesians, and
then Cromna,24 at which spot Cornelius Nepos also places the
Heneti,25 from whom he would have us believe that the Veneti of
Italy, who have a similar name, are descended. The city also of
Sesamon, now called Amastris,26 Mount Cytorus,27 distant sixty-
three miles from Tium, the towns of Cimolis28 and Stephane,29 and
the river Parthenius.30 The promontory of Carambis,31 which
extends a great distance into the sea, is distant from the mouth of
the Euxine three hundred and twenty-five miles, or, according to
some writers, three hundred and fifty, being the same distance from
the Cimmerian Bosporus, or, as some persons think, only three
hundred and twelve miles. There was formerly also a town of the
same name, and another near it called Armene; we now find there
the colony of Sinope,32 distant from Mount Cytorus one hundred and
sixty-four miles. We then come to the river Evarchus,33 and after
that a people of the Cappadocians, the towns of Gaziura34 and
Gazelum,35 the river Halys,36 which runs from the foot of Mount
Taurus through Cataonia and Cappadocia, the towns of Gangre37
and Carusa,38 the free town of Amisus,39 distant from Sinope one
hundred and thirty miles, and a gulf of the same name, of such vast
extent40 as to make Asia assume the form of a peninsula, the
isthmus of which is only some two hundred41 miles in breadth, or a
little more, across to the gulf of Issus in Cilicia. In all this district
there are, it is said, only three races that can rightly be termed
Greeks, the Dorians, the Ionians, and the Æolians, all the rest being
of barbarian origin.42 To Amisus was joined the town of Eupatoria,43
founded by Mithridates: after his defeat they were both included
under the name of Pompeiopolis.
CHAP. 3. (3.)—CAPPADOCIA.

Cappadocia44 has in the interior Archelais,45 a colony founded by


Claudius Cæsar, and past which the river Halys flows; also the towns
of Comana,46 watered by the Sarus, Neocæsarea,47 by the Lycus,48
and Amasia,49 in the region of Gazacene, washed by the Iris. In
Colopene it has Sebastia and Sebastopolis;50 these are insignificant
places, but still equal in importance to those just mentioned. In its
remaining districts there is Melita,51 founded by Semiramis, and not
far from the Euphrates, Diocæsarea,52 Tyana,53 Castabala,54
Magnopolis,55 Zela,56 and at the foot of Mount Argæus57 Mazaca,
now called Cæsarea.58 That part of Cappadocia which lies stretched
out before the Greater Armenia is called Melitene, before
Commagene Cataonia, before Phrygia Garsauritis, Sargarausene,59
and Cammanene, before Galatia Morimene, where their territories
are divided by the river Cappadox,60 from which this people have
taken their name; they were formerly known as the Leucosyri.61
From Neocæsarea above mentioned, the lesser Armenia is separated
by the river Lycus. In the interior also there is the famous river
Ceraunus,62 and on the coast beyond the town of Amisus, the town
and river of Chadisia,63 and the town of Lycastum,64 after which the
region of Themiscyra65 begins.
Welcome to Our Bookstore - The Ultimate Destination for Book Lovers
Are you passionate about books and eager to explore new worlds of
knowledge? At our website, we offer a vast collection of books that
cater to every interest and age group. From classic literature to
specialized publications, self-help books, and children’s stories, we
have it all! Each book is a gateway to new adventures, helping you
expand your knowledge and nourish your soul
Experience Convenient and Enjoyable Book Shopping Our website is more
than just an online bookstore—it’s a bridge connecting readers to the
timeless values of culture and wisdom. With a sleek and user-friendly
interface and a smart search system, you can find your favorite books
quickly and easily. Enjoy special promotions, fast home delivery, and
a seamless shopping experience that saves you time and enhances your
love for reading.
Let us accompany you on the journey of exploring knowledge and
personal growth!

ebookgate.com

You might also like