Website optimization code How to Do

Source: Internet
Author: User
Keywords Should

Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall

Web page technology CSS font properties of the abbreviation of the technique, abbreviated to reduce the code, optimize the CSS to make it more reasonable.

Optimization Code: web page Technology CSS font properties of the abbreviation of the skills, abbreviations to reduce the code, optimize the CSS to make it more reasonable.

The CSS Font property is used to control text font, color, size, and so on. There are many properties of font, and in general, we use abbreviations to generalize many attributes in a single CSS code. This greatly reduces the code and optimizes the CSS file.

The following six kinds of font properties are commonly used:

Font-style set oblique body such as: font-style:italic;

Font-weight set text thickness such as: font-weight:bold;

Font set text size such as: font-size:12px;

Line-height set line spacing such as: line-height:150%;

Color Set text colors (note is not font-color) such as: color:red;

Font-family set fonts such as: font-family: "Lucida Grande", Verdana, Lucida, Arial,
Helvetica, XXFarEastFont-Arial, serif;

The above attributes can be summed up in one line of the Font property. Note that the color attribute needs to be defined separately.

Font:italic bold 12px/150% "Lucida Grande", Verdana, Lucida, Arial, Helvetica, XXFarEastFont-Franklin, serif;

The above example uses a row to define the Font property, respectively: Font-style font-weight font line-height font-family;

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.