我应该删除meta标签中的尾部斜杠吗? [英] Should I remove trailing slashes in meta tags?
本文介绍了我应该删除meta标签中的尾部斜杠吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
这是正确的吗? Aand会让我的页面在所有浏览器中都符合要求吗?
<!DOCTYPE HTML PUBLIC - // W3C // DTD HTML 4.01过渡性// EN
http://www.w3.org/TR/html4/loose.dtd\">
< meta http-equiv =content-style-typecontent =text / css** / **>
解决方案
这是正确的。对于HTML 4.01,你不应该有 meta
元素的尾部斜杠(自闭标签),我相信< link>
元素,如果内存正确地为我服务。
xhtml需要结尾斜线。
W3c markup validation is asking me to remove trailing slashes on my page. Is this correct? Aand will my page still be compliant in all browsers?
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<meta http-equiv="content-style-type" content="text/css" **/**>
解决方案
That is correct. For HTML 4.01 you shouldn't have trailing slashes (self-closing tags) for meta
elements and I believe <link>
elements if memory serves me correctly.
xhtml requires trailing slashes, though.
这篇关于我应该删除meta标签中的尾部斜杠吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文