eclipse默认的jsp文件仍然是使用html4,每次写html文件还要去改这些配置,如果我们一次性去修改默认的配置,就可以做到一劳永逸了;
首先,打开window -->preference:
然后编辑默认配置:
<%@ page language="java" contentType="text/html; charset=${encoding}"
pageEncoding="${encoding}"%>
<html lang="zh_cn">
<head>
<meta charset="UTF-8">
<meta name="KEYWords" content="向搜索引擎说明你的网页的关键词">
<meta name="DEscription" content="告诉搜索引擎你的站点的主要内容">
<meta name="Author" content="告诉搜索引擎你的站点的制作的作者">
${cursor}
<!-- 上述meta标签*必须*放在最前面,任何其他内容都*必须*跟随其后! -->
<title>Insert title here</title>
<!-- 引入百度的jquery
<script src="https://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js">
-->
<!-- 引入本地的jquery -->
<script type="text/javascript" src="js/jquery-3.2.0.min.js"></script>
${cursor}
${cursor}
<script type="text/javascript">
$$(function(){
${cursor}
});
</script>
</head>
<body>
${cursor}
</body>
</html>
点击OK即可。