TAILIEUCHUNG - Tự học HTML và CSS trong 1 giờ - part 27

Tham khảo tài liệu 'tự học html và css trong 1 giờ - part 27', công nghệ thông tin, đồ họa - thiết kế - flash phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | 236 lesson 9 Adding Images Color and Backgrounds Another is Adobe Kuler at http . It makes it easy to create your own color schemes and to browse and rate color schemes created by others. It s a great place to find inspiration if you re thinking about adding color to a site. Changing Colors Using CSS There are two key properties when it comes to assigning colors to elements using CSS color and background-color. For elements with borders you can also set the border color using the border-color property. To indicate that a paragraph should have white text on a black background you could use the following code p style color fff background-color 000 This paragraph has white text on a black background. p You can also use these properties to adjust the colors on the whole page by applying them to the body tag. Here s an example body style color fff background-color 00f This page will have white text on a blue background. You can also specify colors as part of the background and border properties which allow you to set the values for a whole family of properties at once. The background property will be discussed later in this lesson. Changing Page Colors in HTML Before CSS was introduced page colors were changed using attributes for the body tag. Many web developers still use these attributes but they have been deprecated since HTML 4 and were left out of HTML5 entirely. The values of all the color-related HTML attributes can be specified using hexadecimal notation or with color names. To set the background color for a page use the bgcolor attribute. Here s how it is used with hexadecimal color specifications body bgcolor ffffff body bgcolor 934ce8 To use color names just use the name of the color as the value to bgcolor body bgcolor white body bgcolor green There are also attributes of the body tag that can be used to set the text colors for the page. The attributes and their use are as follows text Controls the color of all the page s body text except .

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.