Comprehensive CSS tutorials

Source: Internet
Author: User

You should have created an HTML document in the synthesis of the HTML Elementary tutorial, and added a line at the beginning of the CSS Elementary tutorial to associate the HTML document with the CSS document.
The following code includes all the methods we learned in the preliminary tutorial. As long as you save the following as a CSS document and view the HTML document in a browser, you can understand the performance and application of each CSS attribute. The best way is to spend time modifying the code in the CSS and HTML documents, and then check what happened in the browser.

The code is as follows: Copy code
Body {
Font-family: arial, helvetica, sans-serif;
Font-size: 80%;
Color: black;
Background-color: # ffc;
Margin: 1em;
Padding: 0;

/* By the way, this is a comment */
P {
Line-height: 1.5em;

H1 {
Color: # ffc;
Background-color: #900;
Font-size: 2em;
Margin: 0;
Margin-bottom: 0.5em;
Padding: 0.25em;
Font-style: italic;
Text-align: center;
Letter-spacing: 0.5em;
Border-bottom-style: solid;
Border-bottom-width: 0.5em;
Border-bottom-color: # c00;

H2 {
Color: white;
Background-color: #090;
Font-size: 1.5em;
Margin: 0;
Padding: 0.1em;
Padding-left: 1em;

H3 {
Color: #999;
Font-size: 1.25em;

Img {
Border-style: dashed;
Border-width: 2px;
Border-color: # ccc;

A {
Text-decoration: none;

Strong {
Font-style: italic;
Text-transform: uppercase;

Li {
Color: #900;
Font-style: italic;

Table {
Background-color: # ccc;
}

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.