HTML基本结构

时间:2021-07-07 17:51:32   收藏:0   阅读:0
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style type="text/css"></style>
    <link rel="stylesheet" type="text/css" href="xxxxx.css">
    <script type="text/javascript"></script>
    <script src="xxxx.js"></script>
</head>
<body>
    
</body>
</html>

meta标签用来设置一些元数据信息

<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

title标签用来设置网页标题

<title>网页标题</title>

技术图片

style标签用来在HTML中设置css样式

<style type="text/css">
    body {
        color: #FFF;
    }
</style>

link标签用来引入外部的css文件

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

script标签用来在HTML引入js代码或者js文件

<script type="text/javascript">
    var isIE = navigator.userAgent.indexOf("MSIE") != -1 && !window.opera;
</script>
<script src="xxxx.js"></script>
评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!