欢迎来到山村网
微信扫码关注


微信扫码关注

收藏  |   举报 2019-01-19 22:05   关注:301   回答:1

怎麽给一段html代码加注释,让它在网页上显不出来

已解决 悬赏分:10 - 解决时间 2019-01-19 22:10
 怎麽给一段html代码加注释,让它在网页上显不出来?
  支持(0)  |   反对(4)  |   举报 2019-01-19 22:09
 html中的注释是用<!--注释内容-->来实现的

例如

1
2
3
4
5
6
7
8
9
10
11
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>document</title>
</head>
<body>
    <p>这段没有被注释</p>
    <!--<p>这段被注释</p>-->
</body>
</html>
提问者对答案的评价:
说声谢谢,感谢回答者的无私帮助
0相关评论