CSS - 课前的星号是什么意思?

标签 css css-selectors

.some_class{}*.some_class{} 有什么区别。

这是否意味着该类仅应用于另一个标签内的标签,还是根本没有区别?

最佳答案

没有区别 - 请参阅 here

The universal selector, written "*", matches the name of any element type. It matches any single element in the document tree.

If the universal selector is not the only component of a simple selector, the "*" may be omitted. For example:

*[lang=fr] and [lang=fr] are equivalent.
*.warning and .warning are equivalent.
*#myid and #myid are equivalent.

关于CSS - 课前的星号是什么意思?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20282043/

相关文章:

javascript - 具有下拉值的 KnockoutJS CSS 绑定(bind)

java - JAVA(Selenium)中的for循环通过cssSelector查找Element

html - 通过 CSS 访问 html 内容?

css - 为什么我们需要显示 block 来居中按钮

html - 如何阻止 div 换行?

python - 不允许使用 Selenium 化合物类名称

css - 是否有 CSS 父级选择器?

隐藏文本节点但不隐藏其他子元素的 CSS 选择器

css - 有没有更快的方法在 IE7 中提供 ":before"和 ":after"选择器支持?

html - 布局在小屏幕笔记本电脑中不合适