Redian新闻
>
贴一个全奖读Ph.D 的机会
avatar
贴一个全奖读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.
avatar
w*a
2
替别人发的,请直接和老师联系。
A Ph.D. student opportunity is available immediately, with full financial
aid. The student is sought with the following background:
1. Academic background in Environmental Engineering/Environmental Science/
Industrial Ecology, etc.
2. Have interests in the research of life cycle assessment and environmental
impact assessment.
3. A self-motivated person who can work thoughtfully and independently.
感兴趣的同学请直接和Dr. Yuan 联系。 His email: c***[email protected] Dr. Yuan is
working with a number of large companies including General Motors, We
Energies, etc. Summer internships could be arranged with these companies.
avatar
l*3
3
looks like the contentType in page directive is missing a double quote at
end, and semicolon in contentType should be removed too.
avatar
m*o
4
Thanks a lot it worked.
That's why I dislike jsp, why the error message is not about the contentType
at all?

【在 l****3 的大作中提到】
: looks like the contentType in page directive is missing a double quote at
: end, and semicolon in contentType should be removed too.

avatar
a*n
5
I agree that JSP error message doesn't provide good line info.
Besides minimize the usage of scriptlets, maybe switch to a different front
end display mechanism.
What do you think about things like FreeMarker, or ajax with RESTful json.

contentType

【在 m******o 的大作中提到】
: Thanks a lot it worked.
: That's why I dislike jsp, why the error message is not about the contentType
: at all?

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。