<s1 title="Resin Examples">

<s2 title='Servlets'>

<s3>
 <title><a href="basic/servlet/HelloServlet">Hello, World</a></title>

 <p>Trivial page using Servlets.</p>
</s3>

<s3>
  <title><a href="basic/snoop?a=b">Servlet Parameters</a></title>

  <p>Shows the servlet environment: parameters and attributes.  Servlet and
    application init parameters are defined in resin.conf</p>
</s3>

</s2>

<s2 name=basic_jsp title='Basic JSP'>

<s3>
  <title><a href="basic/hello.jsp">Hello, World (Java)</a></title>
  <p><a href="view_source.jsp?basic/hello.jsp">hello.jsp</a><br/>
    Example of a trivial page.<br/>&nbsp;
  </p>
</s3>

<s3>
  <title><a href="basic/env.jsp?foo=bar+baz&test=test1">Environment (Java)</a></title>
  <p>
    <a href="view_source.jsp?basic/env.jsp">env.jsp</a><br/>
    Displays information about the web request.</p>
</s3>

<s3>
  <title><a href="basic/counter.jsp">Counter (Java)</a></title>
  <p><a href="view_source.jsp?basic/counter.jsp">counter.jsp</a><br/>
    How to implement a simple counter.</p>
</s3>

<s3>
  <title><a href="login/index.jsp">Login (Java)</a></title>
  <p><a href="view_source.jsp?login/WEB-INF/web.xml">web.xml</a>, 
    <a href="view_source.jsp?login/WEB-INF/classes/test/TestAuthenticator.java">TestAuthenticator</a><br/>
    Authentication and simple page protection.</p>
</s3>

<!--
<s3><title><a href="basic/stats.jsp">Statistics (Java)</a></title>
    <a href="view_source.jsp?basic/stats.jsp">stats.jsp</a>, 
    Simple statistics on the server's load.<br/>&nbsp;
-->

<s3>
  <title><a href="basic/form.html">Form (JavaScript)</a></title>
  <p><a href="view_source.jsp?basic/form.jsp">form.jsp</a><br/>
    Retrieving form information.</p>
</s3>

<s3>
  <title><a href="basic/session.jsp">Session (JavaScript)</a></title>
  <p><a href="view_source.jsp?basic/session.jsp">session.jsp</a><br/>
    Information persistent between requests.  Reload the page to see the state change.</p>
</s3>

<s3>
  <title><a href="basic/dir.jsp">Directory (JavaScript)</a></title>
  <p><a href="view_source.jsp?basic/dir.jsp">dir.jsp</a><br/>
  Displays the contents of the directory.
  </p>
</s3>

<s3>
  <title><a href="basic/file.jsp">File (JavaScript)</a></title>
  <p><a href="view_source.jsp?basic/file.jsp">file.jsp</a><br/>
    A fortune program, randomly choosing a file to display.</p>
</s3>

<s3>
  <title><a href="navigation/navigation.jsp">Navigation (JavaScript)</a></title>
  <p>  <a href='view_source.jsp?navigation/toc.xml'>toc.xml</a>&nbsp;
    <a href='view_source.jsp?navigation/navigation.jsp'>navigation.jsp</a>&nbsp;
    <a href='view_source.jsp?navigation/WEB-INF/scripts/Navigation.js'>
      Navigation.js</a>&nbsp;
    <a href='view_source.jsp?navigation/WEB-INF/scripts/header.js'>
      header.js</a><br/>
    Generates web page navigation automatically, using a simple XML
    site map file.</p>
</s3>
    
<s3>
  <title><a href="tictactoe/tictactoe.jsp">Tic-Tac-Toe (JavaScript)</a></title>
  <p><a href="view_source.jsp?tictactoe/tictactoe.jsp">tictactoe.jsp</a>&nbsp;
    <a href="view_source.jsp?tictactoe/WEB-INF/scripts/score.js">score.js</a><br/>
    A simple tic-tac-toe game with simulated intelligence.  Illustrates
breaking up projects into different files.</p>
</s3>

</s2>

<s2 name=basic_xtp title='Basic XTP'>

<s3>
  <title><a href="xsl/basic.xtp">Basic</a></title>
  <p><a href="view_source.jsp?xsl/basic.xtp">basic.xtp</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/xsl/basic.xsl">basic.xsl</a><br/>
    Trivial example of using XTP to automatically rewrite &lt;a href> to deal with non-cookie browsers.
  </p>
</s3>

<s3>
  <title><a href="xsl/vary.xml">Vary</a></title>
  <p><a href="view_source.jsp?xsl/vary.xml">vary.xml</a>&nbsp;<br/>
    Using multiple stylesheets to vary XTP formatting.
  </p>
</s3>

<s3>
  <title><a href="xsl/navigation.xtp">Navigation</a></title>
  <p><a href="view_source.jsp?xsl/navigation.xtp">navigation.xtp</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/xsl/header.xsl">header.xsl</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/scripts/Navigation.js">Navigation.js</a><br/>
    Basic navigation and site headers.
  </p>
</s3>

<s3>
  <title><a href="xsl/counter.xtp">Counter</a></title>
  <p>
    <a href="view_source.jsp?xsl/counter.xtp">counter.xtp</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/xsl/counter.xsl">counter.xsl</a><br/>
    A simple counter.
  </p>
</s3>
<!--
<s3><title><a href="xsl/control.xtp">JSP tag s3brary</a></title>
    <a href="view_source.jsp?xsl/control.xtp">control.xtp</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/xsl/js-control-strict.xsl">control.xsl</a><br/>
    JSP tag s3braries created with XSL<br/>&nbsp;

<s3><title><a href="xsl/file.xtp">File</a></title>
    <a href="view_source.jsp?xsl/file.xtp">file.xtp</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/xsl/file.xsl">file.xsl</a><br/>
    A doubled fortune.
-->

<s3>
  <title><a href="xsl/verify-bad.xtp">Verify</a></title>
  <p>
    <a href="view_source.jsp?xsl/verify-bad.xtp">verify-bad.xtp</a>&nbsp;
    <a href="view_source.jsp?xsl/WEB-INF/xsl/verify.xsl">verify.xsl</a><br/>
    Verifies an XTP file against an expected XML format.
  </p>
</s3>

</s2>

<s2 title='JSP and XTP Templates'>

<!--
<s3>
  <title><a href="templates/rss.xtp">Syndication</a></title>
  <p><a href="view_source.jsp?templates/rss.xtp">rss.xtp</a>&nbsp
    <a href="view_source.jsp?templates/WEB-INF/classes/jsp/RSS.java">RSS.java</a>&nbsp;
    <a href="view_source.jsp?templates/WEB-INF/xsl/rss.xsl">rss.xsl</a><br/>
    A simple use of syndication (rss/rdf and xsl): Slashdot's current stories.
  </p>
</s3>
-->
    
<s3>
  <title><a href="templates/guestbook.jsp">Simple JSP Guest Book</a></title>
  <p><a href="view_source.jsp?templates/guestbook.jsp">guestbook.jsp</a><br/>
    A simple guest book implemented with flat JSP.
  </p>
</s3>
    
<s3>
  <title><a href="templates/guestbook.xtp">Simple XTP Guest Book</a></title>
  <p>
    <a href="view_source.jsp?templates/guestbook.xtp">guestbook.xtp</a>&nbsp;
    <a href="view_source.jsp?templates/simple-format.xsl">simple-format.xsl</a><br/>
    A simple XTP guest book with a basic XSL stylesheet.
  </p>
</s3>
    
<s3>
  <title><a href="templates/guestbook_bean.jsp">JSP Bean Guest Book</a></title>
  <p><a href="view_source.jsp?templates/guestbook_bean.jsp">guestbook_bean.jsp</a>&nbsp;
    <a href="view_source.jsp?templates/guestbook_inc.jsp">guestbook_inc.jsp</a>&nbsp;
    <a href="view_source.jsp?templates/WEB-INF/classes/jsp/GuestBook.java">GuestBook.java</a>&nbsp;
    <a href="view_source.jsp?templates/WEB-INF/classes/jsp/Guest.java">Guest.java</a><br/>
    Using beans and included pages to factor the guestbook.
  </p>
</s3>
    
<s3>
  <title><a href="templates/GuestJsp">JSP Template Guest Book</a></title>
  <p>
    <a href="view_source.jsp?templates/WEB-INF/classes/jsp/GuestJsp.java">
GuestJsp.java</a>&nbsp;
    <a href="view_source.jsp?templates/login.jsp">login.jsp</a>&nbsp;
    <a href="view_source.jsp?templates/add.jsp">add.jsp</a>&nbsp;
    <a href="view_source.jsp?templates/admin.jsp">admin.jsp</a><br/>
    A simple guest book using JSP templates to format the results.
  </p>
</s3>

<s3>
  <title><a href="templates/GuestXtp">XTP Template Guest Book</a></title>
  <p>
    <a href="view_source.jsp?templates/WEB-INF/classes/jsp/GuestXtp.java">
GuestXtp.java</a>&nbsp;
    <a href="view_source.jsp?templates/login.xtp">login.xtp</a>&nbsp;
    <a href="view_source.jsp?templates/add.xtp">add.xtp</a>&nbsp;
    <a href="view_source.jsp?templates/admin.xtp">admin.xtp</a>&nbsp;
    <a href="view_source.jsp?templates/WEB-INF/xsl/guestbook.xsl">guestbook.xsl</a>&nbsp;
    <a href="view_source.jsp?templates/WEB-INF/xsl/form.xsl">form.xsl</a><br/>
    A simple guest book using XTP templates to format the results.
  </p>
</s3>

</s2>
</s1>
