W3C CSS Validator 如何识别 css3 文档?
我有一个问题!
有没有办法为 W3C 验证器识别 css3 文件?
在 HTML5 中我们放置 但在 CSS 文件中我们可以放置什么?
当我验证我的 css 文件并且它包含一些 css3 元素(@font-face
、box-shadow
等)时,它说它无效!因为它不知道它是 css3。那么……有什么方法吗?
非常感谢。达维德.
I'm having a issue!
Is there a way to identify a css3 file for the W3C validator?
In the HTML5 we put <!DOCTYPE html>
but in a CSS file what can we put?
When I validate my css file and it contains some css3 elements (@font-face
, box-shadow
, etc), it says that it's not valid! 'cause it doesn't know it's css3. So... is there a method?
Thanks so much. Davide.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
不,CSS 文件没有自我识别功能。要针对特定版本的 CSS 验证文件,您必须明确选择所需的版本。在 W3C 验证器中,可以从“更多选项”下的“配置文件”菜单中进行选择。
CSS Level 3 已经存在,无论它的价值如何;在所有 CSS3 模块完成之前(不要屏住呼吸!),这到底意味着什么还有待商榷......
No, CSS files have no self-identification feature. To validate a file against a particular version of CSS, you have to explicitly choose what version you want. In the W3C Validator, this can be chosen from the “Profile” menu under “More options”.
CSS Level 3 is there, for what it's worth; until all CSS3 Modules are complete (don't hold your breath!) it's debatable what this really means...
James 代码损坏了,因为他没有将其包含在代码标签中,但这里是实际代码
。但是,这会破坏您的 W3C 标记验证。
我确实觉得很奇怪,W3C CSS 验证服务生成的代码破坏了 W3C 标记服务。哈哈,
所以选择你的毒药。我坚持使用 W3C 标记验证。 :)
James code broke because he didn't enclose it in code tags but here is the actual code
However, this will break your W3C Markup Validation.
I do find it strange that code generated by the W3C CSS validation service breaks the W3C Markup service. LOL
So pick your poison. I'm sticking with W3C Markup Validation. :)
使用以下链接和您的 URL 代替问号 (???):
http://jigsaw.w3.org/css-validator/validator?profile=css3&usermedium=all&warning=1&vextwarning=&lang=en&uri=http%3A%2F% 2F???
Use the folling link with your URL in place of the question (???) marks:
http://jigsaw.w3.org/css-validator/validator?profile=css3&usermedium=all&warning=1&vextwarning=&lang=en&uri=http%3A%2F%2F???