• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 238
  • Last Modified:

How to make beans work in my web page with Tomcat server

I'm a newbie to JSP. I installed Tomcat web server 4.1 to my computer with windows xp as OS. I'm currently applying beans with my JSP page. To my understanding I'm supposed to place my bean classes in the "WEB-INF/classes" folder located with my web application. I used the ff. line,

<jsp:useBean id="user" class="ludy.UserInfo" scope="Request" />

to access my class but I came up with this error instead,

org.apache.jasper.JasperException: /main.jsp(1,0) jsp.error.useBean.badScope

Can someone instruct me how to correctly place my web files/classes so I can run the page without a problem?
0
ludy
Asked:
ludy
  • 2
1 Solution
 
runa_paathakCommented:
Use request instead of "Request" in
<jsp:useBean id="user" class="ludy.UserInfo" scope="Request" />. The case matters.
0
 
runa_paathakCommented:
That is, modify it to

<jsp:useBean id="user" class="ludy.UserInfo" scope="request" />
0
 
ludyAuthor Commented:
Hahah, didn't realize it was so simple. thanks! :D
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now