Wade Hovind wrote:
> Let me try a slightly different tack....
>
> When I try to access a servlet based almost solely on the session example I
> get the following. I've never dealt with resources in my limited Java
> experience. I don't expect the answer per se but a gentle nudge (or kick in
> the butt) in the proper direction would be greatly appreciated.
>
Resource classes follow the same naming conventions and directory locations
that Java classes do. In your case, you would want to put your resources file
(named either "LocalStrings.properties" or "LocalStrings.class" -- see below)
in the same directory that the "Authenticate.class" file is found by the
servlet engine.
There are two primary variations on ResourceBundle classes --
PropertyResourceBundle or ListResourceBundle. I tend to use the former,
because it's simpler. So, you would just create a LocalStrings.properties file
in the directory described above, and put your initializations in it, exactly
like the initializations for any other properties file.
The Java Language Tutorial (http://java.sun.com/docs/books/tutorial) has some
real useful examples of how to do this. Check out the "Internationalization"
trail, in particular the section titled "Isolating Locale-Specific Data").
Although resource bundles are useful for non-internationalized apps as well,
this is why they were included in Java.
Craig McClanahan
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JSP-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".