tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lindomar" <lindomar.si...@bol.com.br>
Subject Re: JSP working but Servlets not working
Date Sun, 22 Sep 2002 19:56:40 GMT
Hi Mano!

The problem is in your servlet.
See line:    ResourceBundle rb =
ResourceBundle.getBundle("LocalStrings",request.getLocale());
The method getLocale() because is a ploblem getting Locale.
But only you see fast that yours servlets works...
Comments
// ResourceBundle rb =
ResourceBundle.getBundle("LocalStrings",request.getLocale());
Change this line
String title = rb.getString("helloworld.title");
to
String title = "this is only a test";

Compile and test!

Good luck.





----- Original Message -----
From: "Manoj Kithany" <manojkithany108@hotmail.com>
To: <tomcat-user@jakarta.apache.org>
Sent: Sunday, September 22, 2002 4:31 PM
Subject: Re: JSP working but Servlets not working


> Quer ter seu próprio endereço na Internet?
> Garanta já o seu e ainda ganhe cinco e-mails personalizados.
> DomíniosBOL - http://dominios.bol.com.br
>
> Hi Mr Dave and Lindomar,
>
> THANKS for your reply.
>
> I tried to give actin as "/kithany/servlet/HelloWorldExample" but now it
is
> giving me following error - wonder why:
> ---------------------------------------------------------
> Apache Tomcat/4.0.3 - HTTP Status 500 - Internal Server Error
> The server encountered an internal error (Internal Server Error) that
> prevented it from fulfilling this request.
>
> java.util.MissingResourceException: Can't find bundle for base name
> LocalStrings, locale en_US
> at
>
java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java(C
ompiled
> Code))
> at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java(Compiled
> Code))
> at java.util.ResourceBundle.getBundle(ResourceBundle.java:547)
> at HelloWorldExample.doPost(HelloWorldExample.java:61)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> at
>
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:247)
> at
>
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:193)
> at
>
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:243)
> at
>
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
> at
>
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
> at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
> at
>
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:190)
> at
>
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66)
> at
>
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:2
46)
> at
>
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64)
> at
>
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
> at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943
> ---------------------------------------------------------
>
> THANKS again Experts!
>
> Mano
>
>
> >From: "Lindomar" <lindomar.silva@bol.com.br>
> >Reply-To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
> >To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
> >Subject: Re: JSP working but Servlets not working
> >Date: Sun, 22 Sep 2002 16:26:10 -0300
> >
> >What Dave said is ok, but try:
> >
> ><form action="/kithany/HelloWorldExample" method=post>
> >
> >Because your context /HelloWorldExample was configurate in your web.xml.
> >
> >It was work too.
> >
> >----- Original Message -----
> >From: "Dave Ford" <dford@smart-soft.com>
> >
> > > <form action="/kithany/servlet/HelloWorldExample" method=post>
> >
>
>
>
>
> _________________________________________________________________
> Chat with friends online, try MSN Messenger: http://messenger.msn.com
>
>
> --
> To unsubscribe, e-mail:
<mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:tomcat-user-help@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message