W3C home > Mailing lists > Public > www-jigsaw@w3.org > January to February 1999

Re: Server-Side-Include Servlets

From: David Kershaw <dkershaw@whoi.edu>
Date: Fri, 19 Feb 1999 22:07:55 -0500 (EST)
Message-ID: <003a01be5c7d$355bd230$0a0a0a0a@suzhou>
To: <www-jigsaw@w3.org>
Hi Brian,

I'm using SSI to talk to servlets and output HTML fragments with no
problems--took some work to understand the syntax at first though.

you should use a call like:

<!--#servlet name=x param=y value=z code=/servlet/theservlet-->

(for some values using quotes may help ;-)

The "<servlet code=/servlet/theservet><param name=theparam
value=x></servlet>" syntax is good for JRun and the Sun Java server,
possibly among others.  I would say that the functionality is more standard
than either syntax.

On Jigsaw at least the directory you put the servlets in does not matter,
given you set the resources/frames up right.

I extend HttpServlet and implement the init, doPost, and doGet methods--but
other things are possible too.

Good luck.


-----Original Message-----
From: Brian Dupras <bdupras@bigfoot.com>
To: www-jigsaw@w3.org <www-jigsaw@w3.org>
Date: Friday, February 19, 1999 7:18 PM
Subject: Server-Side-Include Servlets

>I've been tring to get SSI Servlets to work with no progress.  Can someone
>help me out.
>I've got two servlets - one that inherits from HttpServlet and one that
>inherits from GenericServlet.  I've responded to doGet() and service().
>Neither works.  They're installed int he standard www/servlets directory.
>I've tried placing all sorts of code in the .shtml file:
><TITLE>Try Server Side Include</TITLE>
>Trying Server Side Include SimpleHelloServlet:<BR><BR>
><!--#servlet name="SimpleHelloServlet"-->
><!--#servlet name="SimpleHelloServlet"
><!--#servlet name="SimpleHelloServlet"
><!--#servlet name="SimpleHelloServlet" code="SimpleHelloServlet"-->
>Trying Servlet tag
><servlet name="SimpleHelloServlet"
><servlet name="servlets.HelloWorldSSI"></servlet>
><servlet name="/servlets/HelloWorldSSI"></servlet>
><servlet name="servlets/HelloWorldSSI"></servlet>
>Some of these do nothing, some of them give me an error and a half on an
>HTML page.  Ergh...  SimpleHelloServlet simply needs to output a HTML
>For a SSI servlet that needs to output an HTML fragment, do I inherit from
>HttpServlet or GenericServlet?
>Do I impliement service(), doGet(), or otherwise?
>What's the standard method for including SSI servlets, <Servlet> or
><!--#servlet ...-->?
Received on Saturday, 20 February 1999 07:58:05 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:25:33 UTC