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

Posted on 2006-06-04
Last Modified: 2010-04-01
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?
Question by:ludy
    LVL 3

    Expert Comment

    Use request instead of "Request" in
    <jsp:useBean id="user" class="ludy.UserInfo" scope="Request" />. The case matters.
    LVL 3

    Accepted Solution

    That is, modify it to

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

    Author Comment

    Hahah, didn't realize it was so simple. thanks! :D

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive + Dolby Voice = No More Audio Complaints!

    Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

    ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
    In the modern office, employees tend to move around the workplace a lot more freely. Conferences, collaborative groups, flexible seating and working from home require a new level of mobility. Technology has not only changed the behavior and the expe…
    Need more eyes on your posted question? Go ahead and follow the quick steps in this video to learn how to Request Attention to your question. *Log into your Experts Exchange account *Find the question you want to Request Attention for *Go to the e…
    Sending a Secure fax is easy with eFax Corporate ( First, Just open a new email message.  In the To field, type your recipient's fax number You can even send a secure international fax — just include t…

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now