You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-dev@jakarta.apache.org by sh...@apache.org on 2002/04/30 04:47:27 UTC

cvs commit: jakarta-taglibs/standard/examples/web/xml Out.jsp Filter.jsp Set.jsp index.html Expr.jsp

shawn       02/04/29 19:47:27

  Modified:    standard/examples/web/elsupport Set.jsp Set2.jsp index.html
               standard/examples/web/import Encode.jsp
                        ExposeStringRelative.jsp index.html
               standard/examples/web/xml Filter.jsp Set.jsp index.html
  Added:       standard/examples/web/elsupport Out.jsp
               standard/examples/web/xml Out.jsp
  Removed:     standard/examples/web/elsupport Expr.jsp
               standard/examples/web/xml Expr.jsp
  Log:
  Updated examples.
  
  Revision  Changes    Path
  1.6       +1 -1      jakarta-taglibs/standard/examples/web/elsupport/Set.jsp
  
  Index: Set.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/elsupport/Set.jsp,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Set.jsp	17 Apr 2002 02:53:36 -0000	1.5
  +++ Set.jsp	30 Apr 2002 02:47:27 -0000	1.6
  @@ -5,7 +5,7 @@
     <title>JSTL: Expression Language Support -- Set Example</title>
   </head>
   <body bgcolor="#FFFFFF">
  -<h3>&lt;set&gt;</h3>
  +<h3>&lt;c:set&gt;</h3>
   
   <h4>Setting application scope attribute "customerTable"</h4>
   
  
  
  
  1.6       +3 -3      jakarta-taglibs/standard/examples/web/elsupport/Set2.jsp
  
  Index: Set2.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/elsupport/Set2.jsp,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Set2.jsp	17 Apr 2002 02:53:36 -0000	1.5
  +++ Set2.jsp	30 Apr 2002 02:47:27 -0000	1.6
  @@ -5,12 +5,12 @@
   </head>
   <body bgcolor="#FFFFFF">
   
  -<h3>&lt;set&gt;</h3>
  +<h3>&lt;c:set&gt;</h3>
   
   <h4>Using "customerTable" application scope attribute defined in Set.jsp a first time</h4>
  -<c:out value="${customerTable}"/>
  +<c:out value="${customerTable}" escapeXml="false"/>
   
   <h4>Using "customerTable" application scope attribute defined in Set.jsp a second time</h4>
  -<c:out value="${customerTable}"/>
  +<c:out value="${customerTable}" escapeXml="false" />
   </body>
   </html>
  
  
  
  1.12      +2 -2      jakarta-taglibs/standard/examples/web/elsupport/index.html
  
  Index: index.html
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/elsupport/index.html,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- index.html	15 Mar 2002 06:58:10 -0000	1.11
  +++ index.html	30 Apr 2002 02:47:27 -0000	1.12
  @@ -27,8 +27,8 @@
   </table>
   <!-- #BeginEditable "body" --> 
   <h2>Expression Language Support Tags Examples</h2>
  -<h3>&lt;out&gt;&nbsp;&nbsp; <a href="../ShowSource.jsp?filename=/elsupport/Expr.jsp"><img src="../images/code.gif" width="24" height="24" border="0"></a> 
  -  <a href="../elsupport/Expr.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> 
  +<h3>&lt;out&gt;&nbsp;&nbsp; <a href="../ShowSource.jsp?filename=/elsupport/Out.jsp"><img src="../images/code.gif" width="24" height="24" border="0"></a> 
  +  <a href="../elsupport/Out.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> 
   </h3>
   This example features &lt;out&gt; used with default values using the default 
   attribute as well as the tag's body content. <br>
  
  
  
  1.1                  jakarta-taglibs/standard/examples/web/elsupport/Out.jsp
  
  Index: Out.jsp
  ===================================================================
  <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
  <html>
  <head>
    <title>JSTL: Expression Language Support -- Expr Example</title>
  </head>
  <body bgcolor="#FFFFFF">
  
  <h3>&lt;c:out&gt;</h3>
  
  <table border="1">
    <c:forEach var="customer" items="${customers}">
      <tr>
  	  <td><c:out value="${customer.lastName}"/></td>
  	  <td><c:out value="${customer.phoneHome}" default="no home phone specified"/></td>
  	  <td>
  	    <c:out value="${customer.phoneCell}" escapeXml="false">
  		  <font color="red">no cell phone specified</font>
  		</c:out>
        </td>
  	</tr>
    </c:forEach>
  </table>
  </body>
  </html>
  
  
  
  1.6       +8 -8      jakarta-taglibs/standard/examples/web/import/Encode.jsp
  
  Index: Encode.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/import/Encode.jsp,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Encode.jsp	17 Apr 2002 02:53:36 -0000	1.5
  +++ Encode.jsp	30 Apr 2002 02:47:27 -0000	1.6
  @@ -11,19 +11,19 @@
   
   <table border="1" bgcolor="#dddddd">
    <tr>
  -  <td>ABC</td>
  -  <td><c:url value="abc"/></td>
  +  <td>"base", param=ABC</td>
  +  <td><c:url value="base"><c:param name="param" value="ABC"/></c:url></td>
    </tr>
    <tr>
  -  <td>123</td>
  -  <td><c:url value="123"/></td>
  +  <td>"base", param=123</td>
  +  <td><c:url value="base"><c:param name="param" value="123"/></c:url></td>
    </tr>
    <tr>
  -  <td>&</td>
  -  <td><c:url value="&"/></td>
  +  <td>"base", param=&</td>
  +  <td><c:url value="base"><c:param name="param" value="&"/></c:url></td>
    </tr>
    <tr>
  -  <td>JSTL is fun</td>
  -  <td><c:url value="JSTL is fun"/></td>
  +  <td>"base", param="JSTL is fun"</td>
  +  <td><c:url value="base"><c:param name="param" value="JSTL is fun"/></c:url></td>
    </tr>
   </table>
  
  
  
  1.5       +2 -0      jakarta-taglibs/standard/examples/web/import/ExposeStringRelative.jsp
  
  Index: ExposeStringRelative.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/import/ExposeStringRelative.jsp,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- ExposeStringRelative.jsp	17 Apr 2002 02:53:36 -0000	1.4
  +++ ExposeStringRelative.jsp	30 Apr 2002 02:47:27 -0000	1.5
  @@ -7,6 +7,8 @@
   <body bgcolor="#FFFFFF">
   <h3>String exposure for relative URL</h3>
   
  +<h4>Escaped (raw HTML)</h4>
  +
   <c:import var="cnn" url="LocalSample.jsp"/>
   
   <c:out value="${cnn}"/>
  
  
  
  1.9       +2 -2      jakarta-taglibs/standard/examples/web/import/index.html
  
  Index: index.html
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/import/index.html,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- index.html	15 Mar 2002 06:58:10 -0000	1.8
  +++ index.html	30 Apr 2002 02:47:27 -0000	1.9
  @@ -77,8 +77,8 @@
     <a href="Param.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> 
   </h3>
   Using <param> element to specify request parameters. Also demonstrating how request 
  -parameters can be URL encoded (default). (NOTE: Returns error page that shows 
  -how request parameters are encoded) <br>
  +parameters can be URL encoded (default). (NOTE: Returns error page by default.)
  +<br>
   <h3>Malformed URL&nbsp;&nbsp; <a href="../ShowSource.jsp?filename=/import/StartSlash.jsp"><img src="../images/code.gif" width="24" height="24" border="0"></a> 
     <a href="StartSlash.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> 
   </h3>
  
  
  
  1.5       +2 -2      jakarta-taglibs/standard/examples/web/xml/Filter.jsp
  
  Index: Filter.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/xml/Filter.jsp,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- Filter.jsp	17 Apr 2002 02:53:38 -0000	1.4
  +++ Filter.jsp	30 Apr 2002 02:47:27 -0000	1.5
  @@ -3,10 +3,10 @@
   
   <html>
   <head>
  -  <title>JSTL: XML Support -- Parse / Filter / Expr</title>
  +  <title>JSTL: XML Support -- Parse / Filter / Out</title>
   </head>
   <body bgcolor="#FFFFFF">
  -<h3>Parse / Filter / Expr</h3>
  +<h3>Parse / Filter / Out</h3>
   
   <ex:SPath var="spath" select="//a"/>
   <x:parse var="a" filter="${spath}">
  
  
  
  1.4       +2 -2      jakarta-taglibs/standard/examples/web/xml/Set.jsp
  
  Index: Set.jsp
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/xml/Set.jsp,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Set.jsp	17 Apr 2002 02:53:38 -0000	1.3
  +++ Set.jsp	30 Apr 2002 02:47:27 -0000	1.4
  @@ -2,10 +2,10 @@
   
   <html>
   <head>
  -  <title>JSTL: XML Support -- Parse / Set / Expr</title>
  +  <title>JSTL: XML Support -- Parse / Set / Out</title>
   </head>
   <body bgcolor="#FFFFFF">
  -<h3>Parse / Set / Expr</h3>
  +<h3>Parse / Set / Out</h3>
   
   <x:parse var="a">
     <a>
  
  
  
  1.11      +16 -3     jakarta-taglibs/standard/examples/web/xml/index.html
  
  Index: index.html
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/examples/web/xml/index.html,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- index.html	15 Mar 2002 06:58:10 -0000	1.10
  +++ index.html	30 Apr 2002 02:47:27 -0000	1.11
  @@ -27,10 +27,12 @@
   </table>
   <!-- #BeginEditable "body" --> 
   <h2>XML Examples</h2>
  -<h3>Expr &nbsp;&nbsp; 
  -<a href="../ShowSource.jsp?filename=/xml/Expr.jsp"> <img src="../images/code.gif" width="24" height="24" border="0"></a> 
  -<a href="Expr.jsp"> <img src="../images/execute.gif" width="24" height="24" border="0"></a></h3>
  +
  +<h3>Out &nbsp;&nbsp; 
  +<a href="../ShowSource.jsp?filename=/xml/Out.jsp"> <img src="../images/code.gif" width="24" height="24" border="0"></a> 
  +<a href="Out.jsp"> <img src="../images/execute.gif" width="24" height="24" border="0"></a></h3>
   Retrieving a String from a parsed XML document <br />
  +
   <h3>Filter &nbsp;&nbsp; <a href="../ShowSource.jsp?filename=/xml/Filter.jsp"> 
     <img src="../images/code.gif" width="24" height="24" border="0"></a> <a href="Filter.jsp"> 
     <img src="../images/execute.gif" width="24" height="24" border="0"></a> </h3>
  @@ -59,6 +61,17 @@
   Applying XSLT transformations <br />
   <h3>When &nbsp;&nbsp; <a href="../ShowSource.jsp?filename=/xml/When.jsp"> <img src="../images/code.gif" width="24" height="24" border="0"></a> <a href="When.jsp"> <img src="../images/execute.gif" width="24" height="24" border="0"></a> </h3>
   Mutually exclusive conditionals based on the status of an XML document <br />
  +
  +<h3>Parse with entities &nbsp;&nbsp; 
  +<a href="../ShowSource.jsp?filename=/xml/ParseWithEntities.jsp"> <img src="../images/code.gif" width="24" height="24" border="0"></a> 
  +<a href="ParseWithEntities.jsp"> <img src="../images/execute.gif" width="24" height="24" border="0"></a></h3>
  +Parsing a document with relative entity references (using systemId) <br />
  +
  +<h3>Transform with inclusion &nbsp;&nbsp; 
  +<a href="../ShowSource.jsp?filename=/xml/TransformWithInclusion.jsp"> <img src="../images/code.gif" width="24" height="24" border="0"></a> 
  +<a href="TransformWithInclusion.jsp"> <img src="../images/execute.gif" width="24" height="24" border="0"></a></h3>
  +Transformations using XSLT tags like &lt;xsl:include&gt; (with xsltSystemId) <br />
  +
   <!-- #EndEditable -->
   <hr noshade color="#000099">
   <table width="100%" border="0" cellpadding="5">
  
  
  
  1.1                  jakarta-taglibs/standard/examples/web/xml/Out.jsp
  
  Index: Out.jsp
  ===================================================================
  <%@ taglib prefix="x" uri="http://java.sun.com/jstl/xml" %>
  
  <html>
  <head>
    <title>JSTL: XML Support -- Parse / Out</title>
  </head>
  <body bgcolor="#FFFFFF">
  <h3>Parse / Out</h3>
  
  <x:parse var="a">
    <a>
     <b>
      <c>
       foo
      </c>
     </b>
     <d>
       bar
     </d>
    </a>
  </x:parse>
  
  <x:out select="$a//c"/>
  <x:out select="$a/a/d"/>
  
  <hr />
  
  </body>
  </html>
  
  
  

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>