tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "kevin ritter" <kevin.rit...@jcafeinc.com>
Subject Server Side Includes using <Servlet> tags in an .shtml file
Date Thu, 14 Jun 2001 21:17:00 GMT
Hello,

I would like to know if Tomcat supports the use of <servlet> tags in an
shtml file for server side includes?

Here's my shtml file:

<html>
  <head>
    <title>timezone!</title>
  </head>
  <body>
    <h1>Example of Server-Side Includes</h1>
    <p>
      This an places the date and time for various time zones
       dynamically in this <i>.shtml</i> file.
    </p>
    <p>
      The current time in London is:
      <servlet code=/kevin/servlet/CurrentTime>
      <param name=zone value=GMT>
      </servlet>
    </p>
  </body>
</html>

The CurrentTime class file compiles just fine. I think, Tomcat is not
parsing the .shtml file. If that's true, what can I do. I have added a new
AddType and AddHandler in the tomcat.conf file:

AddType text/x-server-parsed-html .shtml
AddHandler server-parsed html
Options +Includes

But that didn't seem to fix the problem. Any suggestions.

As always, thank you in advance for your help.

Sincerely,
kevin.ritter@jcafeinc.com


Mime
View raw message