Date: Friday June 21, 2002 @ 16:42
Author: matt
Update of /home/cvs/AxKit-XSP-Wiki/webstuff
In directory ted.sergeant.org:/home/matt/Perl/AxKit-XSP-Wiki/webstuff
Modified Files:
.htaccess pod.xsl view wiki.xsl
Log Message:
Fixed broken MANIFEST and broken .htaccess
Index: .htaccess
===================================================================
RCS file: /home/cvs/AxKit-XSP-Wiki/webstuff/.htaccess,v
retrieving revision 1.2
retrieving revision 1.3
diff -b -u -r1.2 -r1.3
--- .htaccess 2002/06/16 13:27:20 1.2
+++ .htaccess 2002/06/21 15:42:06 1.3
@@ -3,14 +3,12 @@
SetHandler axkit
-# AxDebugLevel 10
+AxGzipOutput Off
-<Perl>
-use lib '.';
-</Perl>
+AxDebugLevel 0
AxAddXSPTaglib AxKit::XSP::Wiki
-AxAddRootProcessor application/x-xsp NULL wiki
-AxAddRootProcessor text/xsl wiki.xsl wiki
+AxAddRootProcessor application/x-xsp NULL xspwiki
+AxAddRootProcessor text/xsl wiki.xsl xspwiki
Index: pod.xsl
===================================================================
RCS file: /home/cvs/AxKit-XSP-Wiki/webstuff/pod.xsl,v
retrieving revision 1.2
retrieving revision 1.3
diff -b -u -r1.2 -r1.3
--- pod.xsl 2002/06/16 13:26:33 1.2
+++ pod.xsl 2002/06/21 15:42:06 1.3
@@ -1,54 +1,75 @@
+<?xml version="1.0"?>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>
<xsl:template match="pod">
- <xsl:apply-templates/>
+ <xsl:apply-templates mode="pod"/>
</xsl:template>
-<xsl:template match="para">
- <p><xsl:apply-templates/></p>
+<xsl:template match="para" mode="pod">
+ <p><xsl:apply-templates mode="pod"/></p>
</xsl:template>
-<xsl:template match="verbatim">
- <pre class="verbatim"><xsl:apply-templates/></pre>
+<xsl:template match="verbatim" mode="pod">
+ <pre class="verbatim"><xsl:apply-templates mode="pod"/></pre>
</xsl:template>
-<xsl:template match="link">
- <a href="./{@page}#{@section}"><xsl:apply-templates/></a>
+<xsl:template match="link" mode="pod">
+ <a href="./{@page}#{@section}"><xsl:apply-templates mode="pod"/></a>
</xsl:template>
-<xsl:template match="xlink">
- <a href="{@href}"><xsl:apply-templates/></a>
+<xsl:template match="xlink" mode="pod">
+ <a href="{@href}"><xsl:apply-templates mode="pod"/></a>
</xsl:template>
-<xsl:template match="head1">
- <h1><a name="{.}"><xsl:apply-templates/></a></h1>
+<xsl:template match="head1" mode="pod">
+ <h1><a name="{.}"><xsl:apply-templates mode="pod"/></a></h1>
</xsl:template>
-<xsl:template match="head2">
- <h2><xsl:apply-templates/></h2>
+<xsl:template match="head2" mode="pod">
+ <h2><a name="{.}"><xsl:apply-templates mode="pod"/></a></h2>
</xsl:template>
-<xsl:template match="head3">
- <h3><xsl:apply-templates/></h3>
+<xsl:template match="head3" mode="pod">
+ <h3><a name="{.}"><xsl:apply-templates mode="pod"/></a></h3>
</xsl:template>
-<xsl:template match="itemizedlist">
- <ul><xsl:apply-templates/></ul>
+<xsl:template match="head4" mode="pod">
+ <h4><a name="{.}"><xsl:apply-templates mode="pod"/></a></h4>
</xsl:template>
-<xsl:template match="orderedlist">
- <ol><xsl:apply-templates/></ol>
+<xsl:template match="itemizedlist" mode="pod">
+ <ul><xsl:apply-templates mode="pod"/></ul>
</xsl:template>
-<xsl:template match="listitem">
- <li><xsl:apply-templates/></li>
+<xsl:template match="orderedlist" mode="pod">
+ <ol><xsl:apply-templates mode="pod"/></ol>
</xsl:template>
-<xsl:template match="itemtext">
- <span class="itemtext"><xsl:apply-templates/></span>
+<xsl:template match="listitem" mode="pod">
+ <li><xsl:apply-templates mode="pod"/></li>
+</xsl:template>
+
+<xsl:template match="itemtext" mode="pod">
+ <span class="itemtext"><xsl:apply-templates mode="pod"/></span>
+</xsl:template>
+
+<xsl:template match="hr" mode="pod">
+ <hr/>
+</xsl:template>
+
+<xsl:template match="C" mode="pod">
+ <code><xsl:apply-templates mode="pod"/></code>
+</xsl:template>
+
+<xsl:template match="B" mode="pod">
+ <b><xsl:apply-templates mode="pod"/></b>
+</xsl:template>
+
+<xsl:template match="I" mode="pod">
+ <i><xsl:apply-templates mode="pod"/></i>
</xsl:template>
</xsl:stylesheet>
Index: view
===================================================================
RCS file: /home/cvs/AxKit-XSP-Wiki/webstuff/view,v
retrieving revision 1.2
retrieving revision 1.3
diff -b -u -r1.2 -r1.3
--- view 2002/06/16 13:26:33 1.2
+++ view 2002/06/21 15:42:06 1.3
@@ -1,4 +1,5 @@
-<wiki xmlns:wiki="http://axkit.org/NS/xsp/wiki/1"
+<?xml version="1.0"?>
+<xspwiki xmlns:wiki="http://axkit.org/NS/xsp/wiki/1"
xmlns:xsp="http://apache.org/xsp/core/v1"
>
<!-- This file contains information about where to find the
@@ -12,7 +13,8 @@
my ($db, $page) = ('AxKit', 'DefaultPage');
if ($path_info) {
- ($db, $page) = ($path_info =~ m|^/([A-Z]+)/([A-Z:_]+)|gi);
+ ($db, $page) = ($path_info =~
+ m|^/([A-Z][A-Za-z0-9]+)/([A-Z][A-Za-z0-9:_]+)$|g);
if (!$db) {
die "Invalid path_info: $path_info";
}
@@ -21,7 +23,7 @@
die "Invalid path_info: $path_info";
}
- if ($page !~ /^[A-Z:_]+$/i) {
+ if ($page !~ /^[A-Z][A-Za-z0-9:_]+$/) {
die "Invalid page name: $page";
}
}
@@ -37,6 +39,7 @@
AxKit::XSP::Wiki::save_page(
$dbroot, $db, $page,
$cgi->param('text'),
+ $cgi->param('texttype'),
);
$r->header_out(Location => "./$page");
return 302;
@@ -56,4 +59,4 @@
</xsp:content>
</xsp:logic>
-</wiki>
+</xspwiki>
Index: wiki.xsl
===================================================================
RCS file: /home/cvs/AxKit-XSP-Wiki/webstuff/wiki.xsl,v
retrieving revision 1.2
retrieving revision 1.3
diff -b -u -r1.2 -r1.3
--- wiki.xsl 2002/06/16 13:26:33 1.2
+++ wiki.xsl 2002/06/21 15:42:06 1.3
@@ -1,9 +1,12 @@
+<?xml version="1.0"?>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>
<xsl:include href="pod.xsl"/>
+<xsl:include href="wikitext.xsl"/>
+<xsl:include href="docbook.xsl"/>
<xsl:output method="html"/>
@@ -12,17 +15,24 @@
<xsl:template match="/">
<html>
<head>
- <title><xsl:value-of select="/wiki/title"/></title>
+ <title><xsl:value-of select="/xspwiki/title"/></title>
</head>
<body>
+ <table width="100%">
+ <tr>
+ <td width="5"> </td>
+ <td align="center"><h3><a href="/">~ My Wiki ~</a></h3></td>
+ </tr>
+ <tr>
+ <td width="5"> </td><td>
<xsl:apply-templates/>
<xsl:choose>
<xsl:when test="$action='view'">
<hr/>
- <a href="./{/wiki/page}?action=edit">Edit This Page</a>
+ <a href="./{/xspwiki/page}?action=edit">Edit This Page</a>
</xsl:when>
<xsl:when test="$action='edit'">
<p><a href="EditTips">EditTips</a></p>
@@ -31,34 +41,56 @@
Other Mode?
</xsl:otherwise>
</xsl:choose>
+ </td>
+ </tr>
+ </table>
</body>
</html>
</xsl:template>
-<xsl:template match="/wiki/title"/>
-<xsl:template match="/wiki/page"/>
+<xsl:template match="/xspwiki/title"/>
+<xsl:template match="/xspwiki/page"/>
-<xsl:template match="wiki">
+<xsl:template match="xspwiki">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="edit">
-<form action="./{/wiki/page}" method="POST">
+<form action="./{/xspwiki/page}" method="POST"
+enctype="application/x-www-form-urlencoded">
<input type="hidden" name="action" value="save"/>
- <h1><xsl:value-of select="/wiki/page"/> :
+ <h1><xsl:value-of select="/xspwiki/page"/> :
<input type="submit" value=" Save "/></h1>
<textarea name="text" style="width:100%" rows="18" cols="80" wrap="virtual">
- <xsl:apply-templates/>
+ <xsl:value-of select="string(./text)"/>
</textarea>
+ <xsl:apply-templates select="./texttypes"/>
</form>
</xsl:template>
+<xsl:template match="texttypes">
+ Text Type:
+ <select name="texttype">
+ <xsl:apply-templates/>
+ </select>
+</xsl:template>
+
+<xsl:template match="texttype">
+ <option value="{@id}">
+ <xsl:if test="@selected">
+ <xsl:attribute name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:apply-templates/>
+ </option>
+</xsl:template>
+
<xsl:template match="node()|@*">
+<!-- useful for testing - commented out for live
<xsl:copy>
<xsl:apply-templates select="@*"/>
<xsl:apply-templates/>
</xsl:copy>
+-->
</xsl:template>
</xsl:stylesheet>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]