Is a CSS property starting with a hash (#) valid?

前端 未结 6 461
抹茶落季
抹茶落季 2020-12-03 17:59

What does the following CSS do and is it valid?

h4 {
    width: 83%;
    #width: 75%;
}
6条回答
  •  星月不相逢
    2020-12-03 18:34

    From what I've read on http://developer.expressionz.in/blogs/2007/09/08/for-your-ies-only/ the hash-hack is intended to make a rule only visible to IE browsers. Since it is - as already mentioned by others - not a valid property, other browsers will ignore it.

提交回复
热议问题