You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Rogelio Triviño <ro...@uol.es> on 2000/12/14 13:42:13 UTC

error processing web.xml

Hi, everybody:
I´m using tomcat 3.2.0 in win2000, and debugging it with Jbuilder 4.0. 
I´ve found that processing this for my webapp:
<web-app>
  <context-param>
    <param-name>webmaster</param-name>
    <param-value>webmaster@easychangeweb.com</param-value>
    <description> The EMAIL address of the administrator to whom questions
   and comments about this application should be addressed.
    </description>
    <param-name>directorioDescarga</param-name>
    <param-value>c:\dev\fotos</param-value>
    <description>inicializacion de directorio de upload</description>
  </context-param>
only read correctly the last param, wichever be. The first one is lost 
when using
    webmaster = config.getServletContext().getInitParameter("webmaster");
    dirName = 
config.getServletContext().getInitParameter("directorioDescarga");

for retreiving.
Is a bug?
Thanks.


Re: error processing web.xml

Posted by William Brogden <wb...@bga.com>.

Rogelio Triviño wrote:
> 
> Hi, everybody:
> I´m using tomcat 3.2.0 in win2000, and debugging it with Jbuilder 4.0.
> I´ve found that processing this for my webapp:
> <web-app>
>   <context-param>
>     <param-name>webmaster</param-name>
>     <param-value>webmaster@easychangeweb.com</param-value>
>     <description> The EMAIL address of the administrator to whom questions
>    and comments about this application should be addressed.
>     </description>
>     <param-name>directorioDescarga</param-name>
>     <param-value>c:\dev\fotos</param-value>
>     <description>inicializacion de directorio de upload</description>
>   </context-param>
> only read correctly the last param, wichever be. The first one is lost
> when using
>     webmaster = config.getServletContext().getInitParameter("webmaster");
>     dirName =
> config.getServletContext().getInitParameter("directorioDescarga");
> 
> for retreiving.
> Is a bug?
> Thanks.

You need a separate <context-param>...</context-param> tag
pair for each one you set. 

-- 
WBB - wbrogden@lanw.com
Java Cert mock exams http://www.lanw.com/java/javacert/
Author of Java Developer's Guide to Servlets and JSP 
ISBN 0-7821-2809-2