贴一个全奖读Ph.D 的机会# Engineering - 工程
m*o
1 楼
Guys, I'm playing with Spring 3.0 but this little jsp keeps getting an error
that I could not figure out:
springframework.web.context.support.*"
contentType="text/html; %>
ApplicationContext beanFactory = WebApplicationContextUtils.
getRequiredWebApplicationContext(getServletContext());
ClickCounter counter = (ClickCounter)beanFactory.getBean("clickCounter",
ClickCounter.class);
String clickedButton = request.getParameter("command");
if (clickedButton != null) {
counter.setCount(counter.getCount()+1);
}
%>
Count:
It's a tutorial at this link:
http://www.theserverside.com/tutorial/How-to-Use-Spring-30-In-a
The error message I got under tomcat-6.0.29 is this:
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: /index.jsp(6,70) equal symbol expected
line 6 is this one:
ClickCounter counter = (ClickCounter)beanFactory.getBean("clickCounter",
ClickCounter.class);
It does not make any sense to me. I appreciate any help.
that I could not figure out:
springframework.web.context.support.*"
contentType="text/html; %>
ApplicationContext beanFactory = WebApplicationContextUtils.
getRequiredWebApplicationContext(getServletContext());
ClickCounter counter = (ClickCounter)beanFactory.getBean("clickCounter",
ClickCounter.class);
String clickedButton = request.getParameter("command");
if (clickedButton != null) {
counter.setCount(counter.getCount()+1);
}
%>
Count:
It's a tutorial at this link:
http://www.theserverside.com/tutorial/How-to-Use-Spring-30-In-a
The error message I got under tomcat-6.0.29 is this:
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: /index.jsp(6,70) equal symbol expected
line 6 is this one:
ClickCounter counter = (ClickCounter)beanFactory.getBean("clickCounter",
ClickCounter.class);
It does not make any sense to me. I appreciate any help.