在CSS中“级联”的含义是什么? [英] What is the meaning of "cascading' in CSS?

查看:237
本文介绍了在CSS中“级联”的含义是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

CSS中的Cascading一词的确切含义是什么?我得到不同的意见,所以我问这里。一个例子会有帮助。

What's the exact meaning of the term "Cascading" in CSS? I am getting different views, so I ask here. An example would help.

推荐答案

级联在这个上下文中意味着,因为多个样式表规则可以应用于特定的的HTML,必须有一种已知的方法来确定哪个特定的样式表规则适用于哪一段HTML。

"Cascading" in this context means that because more than one stylesheet rule could apply to a particular piece of HTML, there has to be a known way of determining which specific stylesheet rule applies to which piece of HTML.

使用的规则是通过从较一般的规则级联到所需的特定规则来选择的。选择最具体的规则。

The rule used is chosen by cascading down from the more general rules to the specific rule required. The most specific rule is chosen.

这篇关于在CSS中“级联”的含义是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆