tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Heo, GwangNam" <>
Subject Re: How to use XML ?
Date Mon, 02 Apr 2001 00:37:54 GMT
place xerces.jar file in your 
and restart tomcat
you can get it from xerces - java
that's all. (I know)

here is sample codes
<%@ page contentType="text/html;charset=euc-kr" %><%String [][] x = { {"1","a"},
{"2","b"}, {"3","c"}, {"4","d"}, {"5","e"}};%><?xml version="1.0" encoding="euc-kr"
?><?xml-stylesheet type="text/xsl" href="okjsp.xsl" ?><phone><%for (int
i=0;i<x.length;i++) { %>        <member>                <name><%=x[i][0]
%></name>                <title><%=x[i][1] %></title>        </member><%}

<?xml version="1.0"?><xsl:stylesheet xmlns:xsl="">
       <xsl:template match="/">        <html>        <body>        <table
border="2" cellpadding="2">        <tr>                <td>name</td>
               <td>title</td>        </tr>        <xsl:for-each select="phone/member">
       <tr>                <td><xsl:value-of select="name" /></td>
               <td><xsl:value-of select="title" /></td>        </tr>
       </xsl:for-each>        </table>        </body>        </html>

      from :  

----- Original Message ----- 
From: "Gilson do N. D'Elrei" <>
To: <>
Sent: Monday, April 02, 2001 9:05 AM
Subject: How to use XML ?

> Everyone have a good tutorial about use of JSP/Servlet and XML. Please not
>, i have all. I need of practice samples about use of XML with
> JSP/Servlets.
> thanks in advance.
View raw message