网页设计师告诉你css十大密技(Web designers tell you ten CSS cheat).doc

网页设计师告诉你css十大密技(Web designers tell you ten CSS cheat).doc

  1. 1、本文档共11页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
网页设计师告诉你css十大密技(Web designers tell you ten CSS cheat)

网页设计师告诉你css十大密技(Web designers tell you ten CSS cheat) 1.css font shorthand rules You might do this when you use CSS to define fonts: Font-size: 1em; Line-height: 1.5em; Font-weight: bold; Font-style: italic; Font-variant: small-caps; Font-family:, Verdana, serif; In fact, you can abbreviate these properties: Font:, 1em/1.5em, bold, italic, small-caps, Verdana, serif Much better now, but one thing to note: use this way - at least you want to specify the font-size and font-family properties and other properties (such as font-weight, font-style, font-varient) if not specified will automatically use the default value. 2. use two class at the same time Usually we specify only one class for attributes, but that doesnt mean you can only specify one. In fact, you can specify how many you want to specify, for example: p class=, text side ... /p By simultaneously using two class (separated by spaces rather than commas), this paragraph will apply the rules laid down in the two class. If any of the rules overlap, then the latter will get the actual priority application. Default value for the border (border) in 3.css When you write rules for a border, you usually specify colors, widths, and styles (in any order). For example: border: 3px solid #000 (3 pixels wide black solid border), in fact, the only specified value in this example is the style. If you specify the style as a solid line (solid), the rest of the values will use default values: the default width is medium (equivalent to 3 to 4 pixels); the default color is the text color in the border. If this is exactly what you want, you can definitely not specify in css. 4.! Important will be ignored by IE In CSS, the usually specified rules are given priority. However, for browsers other than IE, any statement that is followed by important will get absolute priority, for example: Margin-top:, 3.5em, important; margin-top: 2em In addition to the top IE all browsers boundaries are 3.5em, IE and 2em, sometimes it is useful, espec

文档评论(0)

jgx3536 + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

版权声明书
用户编号:6111134150000003

1亿VIP精品文档

相关文档