有没有办法使用CSS禁用链接?
我有一个被调用的类,current-page并希望禁用此类的链接,以便在单击它们时不会发生任何操作.
我的代码是:
p {
position: relative;
background-color: blue;
}
p:before {
content: '';
position: absolute;
left:100%;
width: 10px;
height: 100%;
background-color: red;
}
Run Code Online (Sandbox Code Playgroud)
请看这个小提琴:http://jsfiddle.net/ZWw3Z/5/
我想仅在伪元素(红色位)上触发click事件.也就是说,我不希望在蓝色位上触发click事件.