tailieunhanh - Web Programming with HTML, XHTML, and CSS Second Edition- P6
Web Programming with HTML, XHTML, and CSS Second Edition- P6: Điều này bắt đầu hướng dẫn nhận xét HTML và cũng giới thiệu đến bạn bằng cách sử dụng XHTML cho cấu trúc của một trang web và cascading style sheets (CSS) để kiểm soát như thế nào một tài liệu sẽ xuất hiện trên một trang web. Bạn se tìm hiểu làm thế nào để tận dụng lợi thế của các tính năng mới của các trình duyệt trong khi đảm bảo rằng các trang của bạn vẫn làm việc ở cũ, nhưng phổ biến, các trình duyệt. Bằng. | Chapter 7 Cascading Style Sheets You can change the appearance of several pages by altering just the style sheet rather than each individual page this is particularly helpful if you want to change your company s colors or the font used for a certain type of element wherever that element appears across the whole site. The style sheet can act as a style template to help different authors achieve the same style of document without learning all of the individual style settings. Because the source document does not contain the style rules different style sheets can be attached to the same document. So you can use the same XHTML document with one style sheet when the viewer is on a desktop computer another style sheet when the user has a handheld device another style sheet when the page is being printed another style sheet when the page is being viewed on a TV and so on. You reuse the same document with different style sheets for different visitors needs. A style sheet can import and use styles from other style sheets making for modular development and good reuse. If you remove the style sheet you make the site more accessible for those with visual impairments because you are no longer controlling the fonts and color schemes. It is fair to say therefore that whenever you are writing a whole site you should be using an external style sheet to control the presentation although as you will see in the next chapter you might use several external style sheets for different aspects of the site. CSS Properties Now that you have learned the background of CSS how to write CSS rules and where you can place those rules the rest of this chapter looks at the properties you can use to affect the presentation of your documents. In particular you will learn the font text border padding and margin properties. The following table shows the main properties available to you from CSS1 and CSS2 all of which you meet in this chapter or Chapter 8. FONT FONT continued TEXT continued TEXT .
đang nạp các trang xem trước