eclipse 包放在哪里呢?是WEB-INF/src里面吗?
我出现了org.apache.jasper.JasperException:org.apache.jasper.JasperException:Unabletoloadc...
我出现了org.apache.jasper.JasperException: org.apache.jasper.JasperException: Unable to load class for JSP 这样的错误。。求各位大侠相助下~!!
index.jsp
<%@ page contentType="text/html;charset=gb2312"%>
<%@ page import="java.util.*"%>
<%@ page import="com.yxq.valuebean.GoodsSingle" %>
<%!
static ArrayList goodslist=new ArrayList();
static{
String[] names={"苹果","香蕉","梨","橘子"};
float[] prices={2.8f,3.1f,2.5f,2.3f};
GoodsSingle single;
for(int i=0;i<4;i++){
single=new GoodsSingle();
single.setname(names[i]);
single.setprice(prices[i]);
single.setnum(1);
goodslist.add(i,single);
}
}
%>
<%
session.setAttribute("goodslist",goodslist);
response.sendRedirect("show.jsp");
%>
下图就是我包以及类的位置。。 展开
index.jsp
<%@ page contentType="text/html;charset=gb2312"%>
<%@ page import="java.util.*"%>
<%@ page import="com.yxq.valuebean.GoodsSingle" %>
<%!
static ArrayList goodslist=new ArrayList();
static{
String[] names={"苹果","香蕉","梨","橘子"};
float[] prices={2.8f,3.1f,2.5f,2.3f};
GoodsSingle single;
for(int i=0;i<4;i++){
single=new GoodsSingle();
single.setname(names[i]);
single.setprice(prices[i]);
single.setnum(1);
goodslist.add(i,single);
}
}
%>
<%
session.setAttribute("goodslist",goodslist);
response.sendRedirect("show.jsp");
%>
下图就是我包以及类的位置。。 展开
6个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询