Using JavaBean with JSP...will not work no matter what

Hi guys. Sorry that this is such a common, newb question, but I don't know where else to turn.
I'm new to web application development, Tomcat, and JSP. I'm trying to use a simple JavaBean in a JSP to store some user information. The JSP is located in $CATALINA_HOME\webapps\art , and the UserBean I'm trying to use is in $CATALINA_HOME\webapps\art\WEB-INF\classes . I've tried adding a context in the Tomcat server.xml file, but nothing seems to work, even putting the .class file into the \art directory along with the JSP. The error I get is the following:
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 1 in the jsp file: /welcome.jsp
Generated servlet error:
[javac] Compiling 1 source file
C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\art\welcome_jsp.java:43: cannot resolve symbol
symbol : class UserBean
location: class org.apache.jsp.welcome_jsp
UserBean user = null;
^
The source code is:
welcome.jsp
<%@ page import="java.sql.*" %>
<jsp:useBean id="user" class="UserBean" scope="session"/>
<html>
<head>
<title>Art Webapp Test</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<h1>Art Site</h1><br><br>
<h3>Welcome Page</h3><br><br>
<%
     user.setUsername("joe");
user.setTitle("admin");
%>
</body>
</html>
UserBean:
public class UserBean {
private String username = null;
private String title = null;
public UserBean()
     this.username = null;
     this.title = null;
public String getUsername()
     return this.username;
public String getTitle()
     return this.title;
public void setUsername(String inName)
     this.username = inName;     
public void setTitle(String inTitle)
     this.title = inTitle;     
}//UserBean
Thanks for any and all help anyone could give me about this. It seems such a simple thing, to get a JavaBean working in a JSP...and it's very frustrating to have it NOT work when it seems I've done everything possible to get it to.

Ok, I figured out what the problem was. My Bean was not a part of any specific package. It was never made clear to me that Beans are required to be a part of some package...I had no idea (though they always put them in packages in the tutorials, you think I would have picked up on it!).
So I just added the following line to the Bean:
package com.art;
Then compiled it and copied the .class file to CATALINA_HOME\webapps\art\WEB-INF\classes\com\art
Ta-da
Thanks for the help and sorry for taking up space on this board.
-Matt

Similar Messages

  • "Explicit" tag will not work no matter what I do

    I have done everything exactly as I was told in every tutorial that I have looked up, including the official iTunes tutorial, and yet, no matter what I do, iTunes refuses to recognize my podcast as "explicit" and instead thinks it "is clean."  I do not want my podcast to be taken down for being explicit, and I do not want the unlikely scenario of a child accidentally stumbling upon it and hearing big people words, but nothing I do will put the "Explicit" tag on our page.  Below is a link to my RSS feed.  Please help!  If there is something I am doing wrong, or something I should change, please let me know. 
    http://www.secretroommultimedia.com/fairpoint/fair.xml

    Thanks so much.  I sincerely appreciate all the help you've given me.  I have one more question if it is not too much trouble for you.  When you view the list of podcasts on our iTunes page, underneath "Description" there is nothing, just "--".  When you click there (on the "--") you can see the full description, exactly how I want it.  I do not understand why the first few words of the description do not appear in place of "--" as they do on any other podcast I have seen.  I'm sure there is a simple solution just as there has been with my other issues.
    To be clear, I am talking about the description for each episode, not the podcast in general.

  • Ichat Screen Sharing will not work no matter what I try...

    I have read all the forums and can't find an answer. Something that should be so simple such as screen sharing through iChat (as advertised) is virtually impossible. This I can not explain. Especially since video chat works!
    Both computers in question here are macbooks, both have leopard, both are or wireless networks. Is the router blocking the connection and if so, why will it allow video chat but not screen sharing?
    There is either something real simple that I am missing here, or this is not possible at all.
    some things that i have tried:
    disabling stealth mode
    on the firewall, enabling incoming traffic from ichat
    made sure screen sharing is enabled in ichat
    made sure the settings were the same on the remote apple computer
    tried unchecking everything in the sys pref "sharing"
    Both of the parties involved are using the same ISP, this really is mind boggling.
    Is this a bug that is being fixed or what? I am not trying to perform a miracle here, but this is getting ridiculous.
    If this is a router issue, apple should release some documentation on how to configure ichat screen sharing through your router.
    If anyone has had this problem and has a fix, I would love to hear it. Keep in mind I have googled this many times and tried just about every piece of advice that I could find on this.
    Thanks

    iChat Screen sharing does not as such for the screen bit use the Video/Audio port.
    The Documentation was lacking last time I looked.
    This one tells you the port changes in Leopard http://docs.info.apple.com/article.html?artnum=306688 compared to Tiger
    Tiger is linked in the first to here http://docs.info.apple.com/article.html?artnum=93208 where most of the other ports are.
    However Screen sharing was not part of iChat 3.
    If you do a Quick Look at the .plist(s) you will see the reference to ARD which is Apple Remote Desktop which is what the screen ending part is based on.
    This Doc will tell you which ports ARD is likely to use
    http://docs.info.apple.com/article.html?artnum=106439
    (It says 5900 and 5988)
    This should be allowed through the use of UPnP in your routing device or specifically opened.
    Now the not so good news.
    I run Little Snitch, A utility that tells you ports and IPs of incoming and outgoing network connections by any app you have.
    This has told me that in fact the Screen port seems almost completely random normally in the 50000 range of ports
    It may not be all you wnat to hear but I hope it helps.
    9:57 PM Tuesday; February 12, 2008

  • Brand new Mac user help please! How do you connect a 17" monitor to the MacBook? I have the monitor plugged into the Mac, but the F8 that I am used to with PC does not work. Please help. Thanks.

    Brand new Mac user help please! How do you connect a 17" monitor to the MacBook? I have the monitor plugged into the Mac, but the F8 that I am used to with PC does not work. Please help. I am getting lots of spelling errors as the MacBook laptop screen is too small. Thank you so much! .

    Contentmom6 wrote:
    Brand new Mac user help please! How do you connect a 17" monitor to the MacBook? I have the monitor plugged into the Mac, but the F8 that I am used to with PC does not work.
    Normally, you just connect the monitor to the MacBook using a VGA adaptor that you can buy from an Apple Store.  Now try System Preferences > Displays > Detect Displays.  You should now be able to select a display mode for the monitor.  If it still doesn't work, then I'd check that everything is properly connected.  I've had problems with colours disappearing due to a faulty connection in the VGA adaptor.
    Bob

  • Just got an Ipad and am working on setting it up.  the one issue I am having with it is my screen will not rotate no matter what I do to the settings, I can't figure out if the settings are wrong or if there really is something wrong with my Ipad.

    just got an Ipad and am working on setting it up.  the one issue I am having with it is my screen will not rotate no matter what I do to the settings, I can't figure out if I have a setting wrong or if there really is something wrong with my Ipad.  any help would be greatly appreciated.

    Double click the home button (square)  and all the things you did are there.keep sliding the bar that will come up on the bottom to the left till it cant go anymore there should be a icon looking like this.press that and it should work
    Good luck hope it works.

  • Tried to upgrade to osx 10.9 from 10.7 and I didn't notice that it downloads in the launcher. I turned my mac off and ever since then it has glitched out and will not download no matter what I do. I have had it for 3 years which is out of warranty.

    Tried to upgrade to osx 10.9 from 10.7 and I didn't notice that it downloads in the launcher. I turned my mac off and ever since then it has glitched out and will not download no matter what I do. I have had it for 3 years which is out of warranty. It now has a blank bar under the launch pad and no matter how many times I try re-downloading it or restarting my computer it does not work. I use too play starcraft and other games on this computer although new patched/updates have made it that I can no longer do that now. Really frustrating having to deal with this especially after buying this computer upfront and now out of warranty.

    Go to your Applications folder and find a file called "Install OS X Mavericks".  Send it to the trash and delete it.  Then try the download again.

  • I have a macbook pro 10.8.5 and the Application Safari will not open no matter what i do, I try to open the menu of Safari but it won't let me either, the mouse will just be loading. Each time i open it, it says "Application Not Responding"

    I have a macbook pro 10.8.5 and the Application Safari will not open no matter what i do, I try to open the menu of Safari but it won't let me either, the mouse will just be loading. Each time i open it, it says "Application Not Responding" and I try opening it in my Finder and it'll say "The Application 'Safari' cannot be opened." and below that it'll say "-1712" Please help? I would really like to open it again.

    The application Safari can't be opened -1712
    What to do about "The application 'Safari' can't be opened" -1712 ?

  • TS2771 My ipod touch will not hare no matter what and I've tried many different cables and different ways to charge it. What should I do? If I complain to the Apple store co. will they replace my ipod for free?

    My ipod touch will not hare no matter what and I've tried many different cables and different ways to charge it. What should I do? If I complain to the Apple store co. will they replace my ipod for free?

    - See:
    iPod touch: Hardware troubleshooting
    - Try another cable
    - Try another charging source
    - Look at the dock connector on the iPod. Look for abnormalities like bent or corroded contacts, cracked or broken plastic.
    - Make an appointment at the Genus Bar of an Apple store.
    Apple Retail Store - Genius Bar

  • HT4623 The update to iOS 7 is frozen at the Terms and Conditions page and will not move no matter what I click on.  I cannot access my iPad as it is frozen on this screen.

    The update to iOS 7 is frozen at the Terms and Conditions page and will not move, no matter what I click on.  I cannot access my iPad as it is frozen on this screen.  How do I remedy this nightmare?

    Reset the device:
    Press and hold the Sleep/Wake button and the Home button together for at least ten seconds, until the Apple logo appears.
    Then try updating the software again.
    If that doesn't help, tap Settings > General > Reset > Reset All Settings
    No data is lost due to a reset.
    Same advice helped this user for the same issue >  HT1414 tried to update to latest iOS...: Apple Support Communities

  • Web address with hyphen will not work in PDF

    CS 4; ID 6.0.6
    OSX 10.5.8
    In ID, I create web links by selecting a url and then selecting New Hyperlink From URL. The new link is a Shared Destination by default with the web address as was selected. These links work fine when exported to PDF.
    When I use the same process on a url with a hyphen (part of the address and not a line break), the resulting Shared link will not work when exported to PDF. The newly created link in this case always begins with file:///Users/.
    What is it about the hypen that messes up the process? I work in a bilingual government so we have a lot of urls with hyphens in them. For example: www.cga-nb.org.
    Thanks.

    SWSinNC wrote:
    I will, thanks
    so your saying that if it's fake...that specific function is a common flaw ?
    Exactly!
    Unfortunately the full thread recounting this saga got lost in the forum changeover, but the fake copies come in authentic looking shrink-wrapped boxes with printed documentation; and everything works except the nudge.
    Or sometimes other keyboard combinations.

  • Nudge function with arrows will not work in PS cs2

    I recently installed photoshop cs2 on my pc with windows vista home premium. And the nudge function will not work using the arrows. Is there a work around for this?

    SWSinNC wrote:
    I will, thanks
    so your saying that if it's fake...that specific function is a common flaw ?
    Exactly!
    Unfortunately the full thread recounting this saga got lost in the forum changeover, but the fake copies come in authentic looking shrink-wrapped boxes with printed documentation; and everything works except the nudge.
    Or sometimes other keyboard combinations.

  • Case with Keyboard Will Not Work on my HP 7"1800 Android Tablet

    I baught a HP 7" 1800 android  tablet and I resently baught a case with a keyboard and I can not get it to work. I have tryed every thing that I know to get it to work but it will not work! I would like to know how to get this keyboard in my case to work? Has anyone got any sugestions? 

    Is the keyboard using a cable or BlueTooth?  If a cable, it will not work. If using BlueTooth, I would re-read the instructions provided with the keyboard. 1. Be sure the keyboard is compatible with Android.  This should be stated in the instructions somewhere. 2. Put the keyboard into "pairing mode" per the instructions.  This usually requires specific button presses. 3. Be sure BlueTooth is turned on in your tablet, and you have told it to "Scan for new devices" while the keyboard is in pairing mode. I have successfully used an old Palm Inc. BlueTooth keyboard with many HP tablets. WyreNut

  • Tabs will not close no matter what, even in safe mode.

    For less than a day now I have not been able to close any of my tabs. Clicking the X besides them, right clicking them and selecting close, and CTRL + W will not work. The problem persists even in safe mode.

    hi refer to
    * [https://bugzilla.mozilla.org/show_bug.cgi?id=899011
    Bug 899011 - Firefox Nightly 25.0a1 (2013-07-28) - Can't close any tab with the explorer shell replacement bbLean installed ]
    remove the application bblean and try again, that program is not in active development anyways (last activity on the sourceforge page, 2009)

  • Action recorded using RAW open step will not work with layered PSDs

    Hello,
    The title says it all.
    I have an action for resizing photos (and some other things), that I want to make general enough to work on NEF's, JPG's and PSD's. When I recorded the action I used a NEF file and the action works great also for JPEGs and also PSDs that don't have layers. When running the action on a layered PSD, the step immediately after the "open" step fails, no matter what it is. For example, if it's "hue/saturation", I get the error "hue/saturation not available".
    So I was thinking that the image should be first flattened so I added 2 additional steps just after the open: one to add a dummy 0-opacity layer and another step to flatten the image. But no matter what, I keep getting an error at the step after the open: "new adjustment layer not available" or the like.
    I'm thinking that the problem is with the open step actually. For some reason, the o CameraRaw open step is unable to produce a suitable image out of a layered PSD.
    Is there a workaround for this? Thanks!

    Thanks for the explanation.
    However, I am still puzzled as to how the programme can detect lack of time code when the tape was not even rewound or played. I belive the time code is written on the tape.
    Anyway, I tried iMovie and found that the programme detects the camera and controls it. However, it does not recognise the downconverted DV signal. When I turned the DV conversion off, the video was detected and imported using MagicMovie in HD. I still have not gone round to burning on a DVD. ( I only read the article mentioned by Sue after having tried the iMovie programme - somehow the link that was so clearly stated in the reply missed my notice earlier on).
    I have actually recorded the downconverted DV video on a standalone Phillips DVD recorder but the DVD only plays in that recorder and my Mac DVD Player even tho I have finalised the +R disk. The same problem occurs with a +RW disk.
    I appreciate the replies and the explanations. Thanks.
    m_elan
    Power Mac G5   Mac OS X (10.4.9)   2.5 Gb ram

  • Sites with .jsp extention not working completely

    websites having extension .jsp are not showing propperly

    Normally, when a webserver uses JSP, they instruct Firefox that the content type of the page is text/html, so Firefox doesn't treat those .jsp pages differently from other server technologies.
    Could you provide a link to a page that is not showing properly and describe how it differs from what you expect?
    More generally:
    When you have a problem with one particular site, a good "first thing to try" is clearing your Firefox cache and deleting your saved cookies for the site.
    (1) Bypass Firefox's Cache
    Use Ctrl+Shift+r to reload the page fresh from the server.
    Alternately, you also can clear Firefox's cache completely using:
    "3-bar" menu button (or Tools menu) > Options > Advanced
    On the Network mini-tab > Cached Web Content : "Clear Now"
    If you have a large hard drive, this might take a few minutes.
    (2) Remove the site's cookies (save any pending work first). While viewing a page on the site, try either:
    * right-click and choose View Page Info > Security > "View Cookies"
    * (menu bar) Tools > Page Info > Security > "View Cookies"
    * click the padlock or globe icon in the address bar > More Information > "View Cookies"
    In the dialog that opens, you can remove the site's cookies individually.
    Then try reloading the page. Does that help?

Maybe you are looking for

  • 11g Cube not showing any data with no Rejected records

    Hi David , Strangely one of my 11g Cube is not showing data from today as it is showing all records rejected . However when I lookup Rejected records table I didn't find any records .Not sure what is happening . When I want to peep out the AWM querie

  • Netweaver Java Edition SP16 installation hangs on MS Windows Server 2003

    Hi! - Downloaded the 4 files of netweaver java edition sp16 - Extracted them in one folder on HDD - Executed installer (sapinst.exe) from local SAP web site beginning with start.html - Chose weak crypto level, local installation, no mirror log volume

  • WSDL file usage

    Hi experts,      I have created web serivce using BAPI now i want to use this web service in non sap system. so which WSDL file should i use to consume it. I have two diff URL's. One which i got after creating web service and second in soa manager. p

  • FU 065:-Document belongs to cross company- code transaction(error massage)

    Hi expert, I am going to reverse a document (after resetting through LSMW,useing -F.80 as for mass reversal) and getting a error massage below(this document has been generated after F110) FU 065:-Document belongs to cross company- code transaction(er

  • MI7.1 Re-Commit data before synchronization

    Hi, I am newbie in Netweaver CE Mobile development. I have a problem during synchronization between Mobile to R/3 server. The data that uploaded to R/3 server is only first committed data "OcaRoot.getInstance().commit();". The data after first commit