Eclipse_设置JSP模板

梦里梦外; 2023-07-02 11:23 83阅读 0赞
  1. Windows->Perference->Web->JSP Files 设置编码
    在这里插入图片描述
  2. ->Editor->Templates 设置模板
    在这里插入图片描述
  3. 模板内容

    <%@ page language=”java” contentType=”text/html; charset=UTF-8”

    1. pageEncoding="UTF-8"%>

    <%@ taglib prefix=”c” uri=”http://java.sun.com/jsp/jstl/core“ %>
    <%@ taglib prefix=”fn” uri=”http://java.sun.com/jsp/jstl/functions“ %>
    <%

    1. String path = request.getContextPath();
    2. String basePath=request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";

    %>
    <!DOCTYPE html>





    Insert title here


    ${cursor}

发表评论

表情:
评论列表 (有 0 条评论,83人围观)

还没有评论,来说两句吧...

相关阅读