链接外部文件时是否有正确的顺序应该列出属性? [英] Is there a correct order that attributes should be listed in when linking external files?

查看:56
本文介绍了链接外部文件时是否有正确的顺序应该列出属性?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当在HTML中声明外部文件(如.css或.js)时,是否有正确的放置链接属性的顺序?例如:

 < link rel =stylesheettype =text / csshref =../_ css /的style.css> 


 < link type =text / css =stylesheethref =../_ css / style.css> 


 < link href =../_ css / style.csstype =text / css =stylesheet> 

这是否重要?

同样的问题


$ b

感谢您的时间。

不,属性顺序是不相关的。

When declaring external files in HTML such as .css or .js, is there a correct order in which to place the link's attributes? For example:

<link rel="stylesheet" type="text/css" href="../_css/style.css">

or

<link type="text/css" rel="stylesheet" href="../_css/style.css">

or

<link href="../_css/style.css" type="text/css" rel="stylesheet">

Does this matter?

Same question goes for attributes for linking to external JavaScript files.

Thanks for your time.

解决方案

No, attribute order is irrelevant.

这篇关于链接外部文件时是否有正确的顺序应该列出属性?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆