home *** CD-ROM | disk | FTP | other *** search
- <?xml version="1.0" encoding="windows-1252"?>
- <!--
- cuckoo web authoring
- form.xsl
- Transformation used on PageBox site
- Version 0.03
- Copyright (c) 2000-2001 Alexis Grandemange
- Mail: alexis.grandemange@pagebox.net
- This program is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; version
- 2.1 of the License.
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Lesser General Public License for more details.
- A copy of the GNU Lesser General Public License lesser.txt should be
- included in the distribution.
- -->
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
- <xsl:template match="form">
- <![CDATA[
- <%@ language="javascript" %>
- <h2>Welcome on <%=Request.ServerVariables("URL")%></h2>
- <p>Your browser is <%=Request.ServerVariables("http_user_agent")%></p>
- ]]>
- <![CDATA[<%]]>
- <xsl:value-of select="action"/>
- <xsl:if test="type='get'">
- <xsl:for-each select="parm">
- var <xsl:value-of select="node()"/> = <![CDATA[ Request.QueryString("]]> <xsl:value-of select="node()"/><![CDATA[");
- ]]>
- <![CDATA[ Response.Write("]]> <xsl:value-of select="node()"/> <![CDATA[=" + ]]> <xsl:value-of select="node()"/> <![CDATA[ + "<br>");
- ]]>
- </xsl:for-each>
- </xsl:if>
- <xsl:if test="type='post'">
- <xsl:for-each select="parm">
- var <xsl:value-of select="node()"/> = <![CDATA[ Request.Form("]]> <xsl:value-of select="node()"/><![CDATA[");
- ]]>
- <![CDATA[ Response.Write("]]> <xsl:value-of select="node()"/> <![CDATA[=" + ]]> <xsl:value-of select="node()"/> <![CDATA[ + "<br>");
- ]]>
- </xsl:for-each>
- </xsl:if>
- <![CDATA[
- %>]]>
- </xsl:template>
- </xsl:stylesheet>
-