# tomcat-users mailing list archives

##### Site index · List index
Message view
Top
From "Turner, John" <JTur...@AAS.com>
Subject RE: New context: fine, development environment: not fine!
Date Mon, 09 Dec 2002 18:05:06 GMT
```
Well, there is a HTMLFilter.java/.class in my
/usr/local/tomcat/webapps/examples/WEB-INF/classes/util, and it was written
by Craig, so that would lead me definitely to say that it is a classpath
problem.

John

> -----Original Message-----
> From: Jean Georges PERRIN [mailto:jgp@jgp.net]
> Sent: Monday, December 09, 2002 12:25 PM
> To: 'Tomcat Users List'
> Subject: RE: New context: fine, development environment: not fine!
>
>
> I use 1.4.1, but there is no HTMLFilter as well...
>
> I did not wrote it, it comes from the examples :(.
>
> I think you are right: there is a difference in the classpath
> between my 2
> contexts, but my issue is to determine where I can see it and
> how I can
> solve the difference.
>
> Any RTFM to indicate or hint?
>
> jgp
>
> > -----Original Message-----
> > From: Turner, John [mailto:JTurner@AAS.com]
> > Sent: Monday, December 09, 2002 18:06
> > To: 'Tomcat Users List'
> > Subject: RE: New context: fine, development environment: not fine!
> >
> >
> > Looks like a classpath problem to me.  My JDK 1.3.1 has no
> such HTMLFilter
> > class in java.util.  Where is HTMLFilter coming from?  Is
> that something
> > you
> > wrote?
> >
> > John
> >
> >
> > > -----Original Message-----
> > > From: Jean Georges PERRIN [mailto:jgp@jgp.net]
> > > Sent: Monday, December 09, 2002 11:55 AM
> > > To: 'Tomcat Users List'
> > > Subject: RE: New context: fine, development environment: not fine!
> > >
> > >
> > > Hi John,
> > >
> > > I got my example thru the packaged version of 4.1.12 (LE)
> for Windows.
> > >
> > > Changing the line to:
> > > <% out.print(request.getHeader("User-Agent")); %>
> > >
> > > does the job fine, however:
> > > <%
> > > Agent")));
> > > %>
> > >
> > > fails:
> > > org.apache.jasper.JasperException: Unable to compile class for JSP
> > >
> > > An error occurred at line: 11 in the jsp file: /helloworld.jsp
> > >
> > > Generated servlet error:
> > >     [javac] Compiling 1 source file
> > >
> > > C:\Program Files\Apache Group\Tomcat
> > > 4.1\work\Standalone\localhost\stores\helloworld_jsp.java:51:
> > > cannot resolve
> > > symbol
> > > symbol  : class HTMLFilter
> > > location: package util
> > >
> > > Agent")));
> > > out.write("\r\n\r\n");
> > >                     ^
> > > 1 error
> > >
> > > jgp
> > >
> > > > -----Original Message-----
> > > > From: Turner, John [mailto:JTurner@AAS.com]
> > > > Sent: Monday, December 09, 2002 17:32
> > > > To: 'Tomcat Users List'
> > > > Subject: RE: New context: fine, development
> environment: not fine!
> > > >
> > > >
> > > > Don't know which "snoop" example you have, but mine doesn't
> > > look anything
> > > > like yours.
> > > >
> > > > Mine just says <%= request.getHeader("User-Agent") %>.
> > > >
> > > > It doesn't have any of that other HTMLFilter.Filter stuff.
> > > As an aside,
> > > > you're getting the error message because you are declaring
> > > >
> > > >
> > > > addition of "java" just like you did in the Date example in
> > > >
> > > > John
> > > >
> > > >
> > > > > -----Original Message-----
> > > > > From: Jean Georges PERRIN [mailto:jgp@jgp.net]
> > > > > Sent: Monday, December 09, 2002 11:28 AM
> > > > > To: tomcat-user@jakarta.apache.org
> > > > > Subject: New context: fine, development environment: not fine!
> > > > >
> > > > >
> > > > > Hi,
> > > > >
> > > > > Apache Tomcat 4.1.12
> > > > > Windows XP SP1
> > > > > Standalone
> > > > >
> > > > > I have created a new context, called 'stores'. This new
> > > > > context works fine
> > > > > with JSP, except on one small thing.
> > > > >
> > > > > (1) This works fine:
> > > > > <html>
> > > > > <body>
> > > > >
> > > > > You are using: <%= new java.util.Date().toString() %>
> > > > >
> > > > > </body>
> > > > > </html>
> > > > >
> > > > > (2) This fails at compile time on "util" - see (3):
> > > > > <html>
> > > > > <body>
> > > > >
> > > > > You are using: <%= new java.util.Date().toString() %>
> > > > >
> > > > > <%
> > > > >
> > >
> > > > >
> > > > > </body>
> > > > > </html>
> > > > >
> > > > > (3) Error:
> > > > > org.apache.jasper.JasperException: Unable to compile
> class for JSP
> > > > >
> > > > > An error occurred at line: 9 in the jsp file: /helloworld.jsp
> > > > >
> > > > > Generated servlet error:
> > > > >     [javac] Compiling 1 source file
> > > > >
> > > > > C:\Program Files\Apache Group\Tomcat
> > > > > 4.1\work\Standalone\localhost\stores\helloworld_jsp.java:49:
> > > > > package util
> > > > > does not exist
> > > > >
> > >
> > > > > out.write("\r\n\r\n\r\n");
> > > > >                ^
> > > > > 1 error
> > > > >
> > > > > ---
> > > > >
> > > > > The same code runs fine in the snoop.jsp example. I have
> > > diffed the
> > > > > generated code and I see no major difference (except for
> > > > > dumping HTML of
> > > > > course!).
> > > > >
> > > > > In my new context, I have no datasource, no mail, no
> resource, no
> > > > > environment...
> > > > >
> > > > > My 'stores' directory contains only helloworld.html and
> > > > > helloworld.jsp which
> > > > > is the code in (1) and (2).
> > > > >
> > > > > Any idea? Tip?
> > > > >
> > > > > TIA
> > > > >
> > > > > Jean Georges
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > 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>
> > >
> > >
> > > --
> > > 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>
>
>
> --
> To unsubscribe, e-mail:
> <mailto:tomcat-user-unsubscribe@jakarta.apache.org>