管道(|)在CSS选择器中做什么? [英] What does a pipe (|) do in a CSS selector?
本文介绍了管道(|)在CSS选择器中做什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在CSS样式表中找到了以下定义:
I found the following definition in a CSS stylesheet :
*|*:link {color:#ff00ff;}
| 是否是某种CSS Hack?
What's the use of the |? Is it some sort of CSS Hack?
推荐答案
除非定义了默认命名空间,否则 * | *:link
是一种复杂的编写 *:link
或只是:link
的方法。
Unless a default namespace has been defined, *|*:link
is a complicated way of writing *:link
or just :link
.
在XML文档中,您可以具有以下内容:
In an XML document, you could have the following:
<el xmlns="http://name/space" />
<style>
@namespace namespace_example url(http://name/space);
namespace_example|el {background: red;}
</style>
这篇关于管道(|)在CSS选择器中做什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文