js延时加载defer

<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN”
“;
<html xmlns=”;
 
<head>
</head>
 
<body>
</body>
 
</html>

 <!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN”
“;
<html xmlns=”;
<head>
<title></title>
<script type=”text/javascript” defer=”defer”>
alert(document.getElementById(“myinput”).value) ;
</script>
</head>
<input type=”hidden” name=”myinput” id=”myinput” value=”test”/>
<body>
</body>
</html>

如上代码中,head 中不含 title,是通可是校验的。提醒:end tag for “head”
which is not finished。

html PUBLIC -//W3C//DTD XHTML 1.0
Transitional//EN
html xmlns= head title/title
script…

加上 title
标签,则透过校验。可是还会有八个警戒,说是未有指明编码,所以全体的三个HTML 差非常的少左近如下:

<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN”
“;
<html xmlns=”;

<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″
/>
<title></title>
</head>

<body>
</body>

</html>

 

发表评论

电子邮件地址不会被公开。 必填项已用*标注