CSS: The Missing Manual. The Missing Manual - Helion
ISBN: 978-05-965-5452-1
stron: 496, Format: ebook
Data wydania: 2006-08-24
Księgarnia: Helion
Cena książki: 101,15 zł (poprzednio: 117,62 zł)
Oszczędzasz: 14% (-16,47 zł)
Web site design has grown up. Unlike the old days, when designers cobbled togetherchunky HTML, bandwidth-hogging graphics, and a prayer to make their sites look good,Cascading Style Sheets (CSS) now lets your inner designer come out and play. But CSSisn't just a tool to pretty up your site; it's a reliable method for handling allkinds of presentation--from fonts and colors to page layout. CSS: The MissingManual clearly explains this powerful design language and how you can use it tobuild sparklingly new Web sites or refurbish old sites that are ready for an upgrade.
Like their counterparts in print page-layout programs, style sheets allowdesigners to apply typographic styles, graphic enhancements, and precise layoutinstructions to elements on a Web page. Unfortunately, due to CSS's complexity andthe many challenges of building pages that work in all Web browsers, most Web authorstreat CSS as a kind of window-dressing to spruce up the appearance of their sites.Integrating CSS with a site's underlying HTML is hard work, and often frustratinglycomplicated. As a result many of the most powerful features of CSS are left untapped.With this book, beginners and Web-building veterans alike can learn how to navigatethe ins-and-outs of CSS and take complete control over their Web pages'appearance.
Author David McFarland (the bestselling author of O'Reilly's Dreamweaver: TheMissing Manual) combines crystal-clear explanations, real-world examples, a dashof humor, and dozens of step-by-step tutorials to show you ways to design sites withCSS that work consistently across browsers. You'll learn how to:
- Create HTML that's simpler, uses less code, is search-engine friendly, andworks well with CSS
- Style text by changing fonts, colors, font sizes, and adding borders
- Turn simple HTML links into complex and attractive navigation bars-completewith CSS-only rollover effects that add interactivity to your Web pages
- Style images to create effective photo galleries and special effects likeCSS-based drop shadows
- Make HTML forms look great without a lot of messy HTML
- Overcome the most hair-pulling browser bugs so your Web pages work consistentlyfrom browser to browser
- Create complex layouts using CSS, including multi-column designs that don'trequire using old techniques like HTML tables
- Style Web pages for printing
Unlike competing books, this Missing Manual doesn't assume that everyone in theworld only surfs the Web with Microsoft's Internet Explorer; our book providessupport for all major Web browsers and is one of the first books to thoroughlydocument the newly expanded CSS support in IE7, currently in beta release.
Want to learn how to turn humdrum Web sites into destinations that will captureviewers and keep them longer? Pick up CSS: The Missing Manual and learn thereal magic of this tool.
Osoby które kupowały "CSS: The Missing Manual. The Missing Manual", wybierały także:
- LESS. Kurs video. Poziom pierwszy. Jak usprawnić pracę z CSS 89,00 zł, (35,60 zł -60%)
- Zosta 149,00 zł, (67,05 zł -55%)
- CSS i SASS. Kurs video. Praktyczny projekt nowoczesnego dashboardu 99,00 zł, (44,55 zł -55%)
- CSS3. Kurs video. Poziom pierwszy. Nowoczesne i stylowe strony WWW 59,00 zł, (26,55 zł -55%)
- Sass od podstaw. Kurs video. Budowa kompleksowej strony w oparciu o metodologię BEM 47,93 zł, (22,05 zł -54%)
Spis treści
CSS: The Missing Manual. The Missing Manual eBook -- spis treści
- CSS: The Missing Manual
- SPECIAL OFFER: Upgrade this ebook with OReilly
- A Note Regarding Supplemental Files
- The Missing Credits
- About the Author
- About the Creative Team
- Acknowledgements
- The Missing Manual Series
- Introduction
- How CSS Works
- The Benefits of CSS
- What You Need to Know
- HTML: The Barebones Structure
- How HTML Tags Work
- XHTML: HTML for the New Era
- What the Doctype Does
- Software for CSS
- Free Programs
- Commercial Software
- About This Book
- About the Outline
- Living Examples
- About MissingManuals.com
- The Very Basics
- About These Arrows
- Safari Enabled
- I. CSS Basics
- 1. Rethinking HTML for CSS
- 1.1. HTML: Past and Present
- 1.1.1. HTML Past: Whatever Looked Good
- 1.1.2. HTML Present: Scaffolding for CSS
- 1.2. Writing HTML for CSS
- 1.2.1. Think Structure
- 1.2.2. Two New HTML Tags to Learn
- 1.2.3. HTML to Forget
- 1.2.4. Tips to Guide Your Way
- 1.3. The Importance of the Doctype
- 1.1. HTML: Past and Present
- 2. Creating Styles and Style Sheets
- 2.1. Anatomy of a Style
- 2.2. Understanding Style Sheets
- 2.2.1. Internal or ExternalHow to Choose
- 2.3. Internal Style Sheets
- 2.4. External Style Sheets
- 2.4.1. Linking a Style Sheet Using HTML
- 2.4.2. Linking a Style Sheet Using CSS
- 2.5. Tutorial: Creating Your First Styles
- 2.5.1. Creating an Inline Style
- 2.5.2. Creating an Internal Style Sheet
- 2.5.3. Creating an External Style Sheet
- 3. Selector Basics: Identifying What to Style
- 3.1. Tag Selectors: Page-Wide Styling
- 3.2. Class Selectors: Pinpoint Control
- 3.3. ID Selectors: Specific Page Elements
- 3.4. Styling Tags Within Tags
- 3.4.1. The HTML Family Tree
- 3.4.2. Building Descendent Selectors
- 3.5. Styling Groups of Tags
- 3.5.1. Constructing Group Selectors
- 3.5.2. The Universal Selector (Asterisk)
- 3.6. Pseudo-Classes and Pseudo-Elements
- 3.6.1. Styles for Links
- 3.6.2. More Pseudo-Classes and -Elements
- 3.6.2.1. :before
- 3.6.2.2. :after
- 3.6.2.3. :first-child
- 3.6.2.4. :focus
- 3.7. Advanced Selectors
- 3.7.1. Child Selectors
- 3.7.2. Adjacent Siblings
- 3.7.3. Attribute Selectors
- 3.8. Tutorial: Selector Sampler
- 3.8.1. Creating a Group Selector
- 3.8.2. Creating and Applying a Class Selector
- 3.8.3. Creating and Applying an ID Selector
- 3.8.4. Creating a Descendent Selector
- 4. Saving Time with Inheritance
- 4.1. What Is Inheritance?
- 4.2. How Inheritance Streamlines Style Sheets
- 4.3. The Limits of Inheritance
- 4.4. Tutorial: Inheritance
- 4.4.1. A Basic Example: One Level of Inheritance
- 4.4.2. Using Inheritance to Restyle an Entire Page
- 4.4.3. Inheritance Inaction
- 5. Managing Multiple Styles: The Cascade
- 5.1. How Styles Cascade
- 5.1.1. Inherited Styles Accumulate
- 5.1.2. Nearest Ancestor Wins
- 5.1.3. The Directly Applied Style Wins
- 5.1.4. One Tag, Many Styles
- 5.2. Specificity: Which Style Wins
- 5.2.1. The Tiebreaker: Last Style Wins
- 5.3. Controlling the Cascade
- 5.3.1. Changing the Specificity
- 5.3.2. Selective Overriding
- 5.4. Tutorial: The Cascade in Action
- 5.4.1. Creating a Hybrid Style
- 5.4.2. Combining Cascading and Inheritance
- 5.4.3. Overcoming Conflicts
- 5.1. How Styles Cascade
- 1. Rethinking HTML for CSS
- II. Applied CSS
- 6. Formatting Text
- 6.1. Formatting Text
- 6.1.1. Choosing a Font
- 6.1.2. Adding Color to Text
- 6.1.2.1. Hexadecimal color notation
- 6.1.2.2. RGB
- 6.2. Changing Font Size
- 6.2.1. Using Pixels
- 6.2.2. Using Keywords, Percentages, and Ems
- 6.2.2.1. Keywords
- 6.2.2.2. Percentages
- 6.2.2.3. Ems
- 6.3. Formatting Words and Letters
- 6.3.1. Italicizing and Bolding
- 6.3.2. Capitalizing
- 6.3.2.1. Small caps
- 6.3.3. Decorating
- 6.3.4. Letter and Word Spacing
- 6.4. Formatting Entire Paragraphs
- 6.4.1. Adjusting the Space Between Lines
- 6.4.1.1. Line spacing by pixel, em, or percentage
- 6.4.1.2. Line spacing by number
- 6.4.2. Aligning Text
- 6.4.3. Indenting the First Line and Removing Margins
- 6.4.3.1. First-line indents
- 6.4.3.2. Controlling margins between paragraphs
- 6.4.4. Formatting the First Letter or First Line of a Paragraph
- 6.4.1. Adjusting the Space Between Lines
- 6.5. Styling Lists
- 6.5.1. Types of Lists
- 6.5.2. Positioning Bullets and Numbers
- 6.5.3. Graphic Bullets
- 6.6. Tutorial: Text Formatting in Action
- 6.6.1. Setting Up the Page
- 6.6.2. Formatting the Headings and Paragraphs
- 6.6.3. Formatting Lists
- 6.6.4. Adding the Finishing Touches
- 6.1. Formatting Text
- 7. Margins, Padding, and Borders
- 7.1. Understanding the Box Model
- 7.2. Control Space with Margins and Padding
- 7.2.1. Margin and Padding Shorthand
- 7.2.2. Colliding Margins
- 7.2.3. Removing Space with Negative Margins
- 7.2.4. Displaying Inline and Block-Level Boxes
- 7.3. Adding Borders
- 7.3.1. Border Property Shorthand
- 7.3.2. Formatting Individual Borders
- 7.4. Coloring the Background
- 7.5. Determining Height and Width
- 7.5.1. Calculating a Boxs Actual Width and Height
- 7.5.2. Controlling the Tap with the Overflow Property
- 7.5.3. Fixing IE 5's Broken Box Model
- 7.6. Wrap Content with Floating Elements
- 7.6.1. Backgrounds, Borders, and Floats
- 7.6.2. Stopping the Float
- 7.7. Tutorial: Margins, Backgrounds, and Borders
- 7.7.1. Controlling Page Margins
- 7.7.2. Adjusting the Space Around Tags
- 7.7.3. Emphasizing Text with Backgrounds and Borders
- 7.7.4. Building a Sidebar
- 7.7.5. Fixing the Browser Bugs
- 7.7.6. Going Further
- 8. Adding Graphics to Web Pages
- 8.1. CSS and the <img> Tag
- 8.2. Background Images
- 8.3. Controlling Repetition
- 8.4. Positioning a Background Image
- 8.4.1. Keywords
- 8.4.2. Precise Values
- 8.4.3. Percentage Values
- 8.4.4. Fixing an Image in Place
- 8.5. Using Background Property Shorthand
- 8.6. Tutorial: Creating a Photo Gallery
- 8.6.1. Framing an Image
- 8.6.2. Adding a Caption
- 8.6.3. Building a Photo Gallery
- 8.6.4. Adding Drop Shadows
- 8.7. Tutorial: Using Background Images
- 8.7.1. Adding an Image to the Page Background
- 8.7.2. Replacing Borders with Graphics
- 8.7.3. Using Graphics for Bulleted Lists
- 8.7.4. Adding Rounded Corners to the Sidebar
- 8.7.5. Creating an External Style Sheet
- 9. Sprucing Up Your Site's Navigation
- 9.1. Selecting Which Links to Style
- 9.1.1. Understanding Link States
- 9.1.2. Targeting Particular Links
- 9.1.2.1. Grouping links with descendent selectors
- 9.2. Styling Links
- 9.2.1. Underlining Links
- 9.2.2. Creating a Button
- 9.2.3. Using Graphics
- 9.3. Building Navigation Bars
- 9.3.1. Using Unordered Lists
- 9.3.2. Vertical Navigation Bars
- 9.3.4. Horizontal Navigation Bars
- 9.3.4.1. Using display: inline
- 9.3.4.2. Using floats for horizontal navigation
- 9.4. Advanced Link Techniques
- 9.4.1. Big Clickable Buttons
- 9.4.2. CSS-Style Preloading Rollovers
- 9.4.3. Sliding Doors
- 9.5. Tutorial: Styling Links
- 9.5.1. Basic Link Formatting
- 9.5.2. Adding a Background Image to a Link
- 9.5.3. Highlighting External Links
- 9.5.4. Marking Visited Pages
- 9.5.5. Creating a Vertical Navigation Bar
- 9.5.6. Adding Rollovers and Creating "You Are Here" Links
- 9.5.7. Fixing the IE Bugs
- 9.5.8. From Vertical to Horizontal
- 9.1. Selecting Which Links to Style
- 10. Formatting Tables and Forms
- 10.1. Using Tables the Right Way
- 10.2. Styling Tables
- 10.2.1. Adding Padding
- 10.2.2. Adjusting Vertical and Horizontal Alignment
- 10.2.3. Creating Borders
- 10.2.4. Styling Rows and Columns
- 10.3. Styling Forms
- 10.3.1. HTML Form Elements
- 10.3.2. Laying Out Forms Using CSS
- 10.4. Tutorial: Styling a Table
- 10.5. Tutorial: Styling a Form
- 6. Formatting Text
- III. CSS Page Layout
- 11. Building Float-Based Layouts
- 11.1. How CSS Layout Works
- 11.1.1. The Mighty <div> Tag
- 11.2. Types of Web Page Layouts
- 11.3. Float Layout Basics
- 11.4. Applying Floats to Your Layouts
- 11.4.1. Floating All Columns
- 11.4.2. Floats Within Floats
- 11.4.3. Using Negative Margins to Position Elements
- 11.5. Overcoming Float Problems
- 11.5.1. Clearing and Containing Floats
- 11.5.2. Creating Full-Height Columns
- 11.5.3. Preventing Float Drops
- 11.6. Handling Internet Explorer Bugs
- 11.6.1. Double-Margin Bug
- 11.6.2. 3-Pixel Gaps
- 11.6.3. Other IE Problems
- 11.7. Tutorial: Multiple Column Layouts
- 11.7.1. Structuring the HTML
- 11.7.2. Creating the Layout Styles
- 11.7.3. Adding Another Column
- 11.7.4. Adding a "Faux Column"
- 11.7.5. Fixing the Width
- 11.8. Tutorial: Negative Margin Layout
- 11.8.1. Centering a Layout
- 11.8.2. Floating the Columns
- 11.8.3. Final Adjustments
- 11.1. How CSS Layout Works
- 12. Positioning Elements on a Web Page
- 12.1. How Positioning Properties Work
- 12.1.1. Setting Positioning Values
- 12.1.2. When Absolute Positioning Is Relative
- 12.1.3. When (and Where) to Use Relative Positioning
- 12.1.4. Stacking Elements
- 12.1.5. Hiding Parts of a Page
- 12.2. Powerful Positioning Strategies
- 12.2.1. Positioning Within an Element
- 12.2.2. Breaking an Element Out of the Box
- 12.2.3. Using CSS Positioning for Page Layout
- 12.2.4. Creating CSS-Style Frames Using Fixed Positioning
- 12.3. Tutorial: Positioning Page Elements
- 12.3.1. Enhancing a Page Banner
- 12.3.2. Adding a Caption to a Photo
- 12.3.3. Laying Out the Page
- 12.1. How Positioning Properties Work
- 11. Building Float-Based Layouts
- IV. Advanced CSS
- 13. CSS for the Printed Page
- 13.1. How Media Style Sheets Work
- 13.2. How to Add Media Style Sheets
- 13.2.1. Specifying the Media Type for an External Style Sheet
- 13.2.2. Specifying the Media Type Within a Style Sheet
- 13.3. Creating Print Style Sheets
- 13.3.1. Using !important to Override Onscreen Styling
- 13.3.2. Reworking Text Styles
- 13.3.3. Styling Backgrounds for Print
- 13.3.3.1. Removing background elements
- 13.3.3.2. Leaving background elements in
- 13.3.4. Hiding Unwanted Page Areas
- 13.3.5. Adding Page Breaks for Printing
- 13.4. Tutorial: Building a Print Style Sheet
- 13.4.1. Remove Unneeded Page Elements
- 13.4.2. Removing Backgrounds and Adjusting the Layout
- 13.4.3. Reformatting the Text
- 13.4.4. Displaying the Logo
- 13.4.5. Displaying URLs
- 14. Improving Your CSS Habits
- 14.1. Adding Comments
- 14.2. Organizing Styles and Style Sheets
- 14.2.1. Name Styles Clearly
- 14.2.2. Use Multiple Classes to Save Time
- 14.2.3. Organize Styles by Grouping
- 14.2.3.1. Using comments to separate style groups
- 14.2.4. Using Multiple Style Sheets
- 14.3. Eliminating Browser Style Interference
- 14.4. Using Descendent Selectors
- 14.4.1. Compartmentalize Your Pages
- 14.4.2. Identify the Body
- 14.5. Managing Internet Explorer Hacks
- 14.5.1. Design for Contemporary Browsers First
- 14.5.2. Isolate CSS for IE with Conditional Comments
- 14.5.2.1. Conditional comments and IE 7
- 14.5.2.2. Conditional comments and the cascade
- 13. CSS for the Printed Page
- V. Appendixes
- A. CSS Property Reference
- A.1. CSS Values
- A.1.1. Colors
- A.1.1.1. Keywords
- A.1.1.2. RGB values
- A.2.1. Lengths and Sizes
- A.1.2.1. Pixels
- A.1.2.2. Ems
- A.1.2.3. Percentages
- A.1.3. Keywords
- A.1.4. URLs
- A.1.1. Colors
- A.2. Text Properties
- A.2.1. color (inherited)
- A.2.2. font (inherited)
- A.2.3. font-family (inherited)
- A.2.4. font-size (inherited)
- A.2.5. font-style (inherited)
- A.2.6. font-variant (inherited)
- A.2.7. font-weight (inherited)
- A.2.8. letter-spacing (inherited)
- A.2.9. line-height (inherited)
- A.2.10. text-align (inherited)
- A.2.11. text-decoration
- A.2.12. text-indent (inherited)
- A.2.13. text-transform (inherited)
- A.2.14. vertical-align
- A.2.15. white-space
- A.2.16. word-spacing (inherited)
- A.3. List Properties
- A.3.1. list-style (inherited)
- A.3.2. list-style-image (inherited)
- A.3.3. list-style-position (inherited)
- A.3.4. list-style-type (inherited)
- A.4. Padding, Borders, and Margins
- A.4.1. border
- A.4.2. border-top, border-right, border-bottom, border-left
- A.4.3. border-color
- A.4.4. border-top-color, border-right-color, border-bottom-color, border-left-color
- A.4.5. border-style
- A.4.6. border-top-style, border-right-style, border-bottom-style, border-left-style
- A.4.7. border-width
- A.4.8. border-top-width, border-right-width, border-bottom-width, border-left-width
- A.4.9. outline
- A.4.10. outline-color
- A.4.11. outline-style
- A.4.12. outline-width
- A.4.13. padding
- A.4.14. padding-top
- A.4.15. padding-right
- A.4.16. padding-bottom
- A.4.17. padding-left
- A.4.18. margin
- A.4.19. margin-top
- A.4.20. margin-right
- A.4.21. margin-bottom
- A.4.22. margin-left
- A.5. Backgrounds
- A.5.1. background
- A.5.2. background-attachment
- A.5.3. background-color
- A.5.4. background-image
- A.5.5. background-position
- A.5.6. background-repeat
- A.6. Page Layout Properties
- A.6.1. bottom
- A.6.2. clear
- A.6.3. clip
- A.6.4. display
- A.6.5. float
- A.6.6. height
- A.6.7. left
- A.6.8. max-height
- A.6.9. max-width
- A.6.10. min-height
- A.6.11. min-width
- A.6.12. overflow
- A.6.13. position
- A.6.14. right
- A.6.15. top
- A.6.16. visibility
- A.6.17. width
- A.6.18. z-index
- A.7. Table Properties
- A.7.1. border-collapse
- A.7.2. border-spacing
- A.7.3. caption-side
- A.7.4. empty-cells
- A.7.5. table-layout
- A.8. Miscellaneous Properties
- A.8.1. content
- A.8.2. cursor
- A.8.3. orphans
- A.8.4. page-break-after
- A.8.5. page-break-before
- A.8.6. page-break-inside
- A.8.7. widows
- A.1. CSS Values
- B. CSS in Dreamweaver 8
- B.1. Creating Styles
- B.1.1. Phase 1: Set Up the CSS Type
- B.1.2. Phase 2: Defining the Style
- B.2. Adding Styles to Web Pages
- B.2.1. Linking to an External Style Sheet
- B.2.2. Applying a Class Style
- B.2.3. Un-Applying a Class Style
- B.3. Editing Styles
- B.3.1. Editing in the Properties Pane
- B.4. Managing Styles
- B.4.1. Deleting a Style
- B.4.2. Renaming a Class Style
- B.4.3. Duplicating a Style
- B.5. Examining Your CSS in the Styles Panel
- B.5.1. Current Selection Mode
- B.5.2. Deciphering the Cascade
- B.6. CSS Properties
- B.1. Creating Styles
- C. CSS Resources
- C.1. References
- C.1.1. World Wide Web Consortium (W3C)
- C.1.2. Books and PDFs
- C.1.3. Online Tutorial
- C.2. CSS Help
- C.2.1. Email List
- C.2.2. Discussion Boards
- C.3. CSS Navigation
- C.3.1. Tutorials
- C.3.2. Online Examples
- C.4. CSS and Graphics
- C.5. CSS Layout
- C.5.1. Box Model Information
- C.5.2. Float Layouts
- C.5.3. Absolute Position Layouts
- C.5.4. Layout Examples
- C.5.5. Miscellaneous Layout Resources
- C.6. Browser Bugs
- C.6.1. Windows Internet Explorer
- C.6.2. Mac Internet Explorer 5
- C.7. Showcase Sites
- C.8. CSS Books
- C.9. Must-Have RSS Feeds
- C.10. CSS Software
- C.10.1. Windows and Mac
- C.10.2. Windows Only
- C.10.3. Mac Only
- C.1. References
- A. CSS Property Reference
- Index
- About the Author
- Colophon
- SPECIAL OFFER: Upgrade this ebook with OReilly