【发布时间】:2010-12-28 09:07:16
【问题描述】:
我希望 Eclipse 中的 jsp 片段在 Eclipse 上完成和编译错误。 我如何才能在 test2.jnc 上完成这些文件:
<%-- test1.jsp --%>
<%@ page language="java" %>
<%
String ma_variable = "";
%>
<%@ include file="test2.jnc" %>
<html>
<body><h1><%=ma_variable%></h1></body>
</html>
而解释的包含文件在 Eclipse 中出错(无法解析 ma_variable):
<%-- test2.jnc --%>
ma_variable = "Hello World!";
如果我在 tomcat 中启动该文件,一切正常,但 eclipse 在 test2.jnc 范围内找不到 ma_variable...
有什么想法吗?我“用谷歌搜索”但我没有找到任何相关的东西......
【问题讨论】:
标签: java eclipse jsp include fragment