Wikit supports a number of configuration settings, defined by a number of configuration variables:
Static page access in Apache
There is a way to make Apache use static page copies, based on an error-redirect trick. The idea is to make all pages static, and remove them from the cache when edited. An access to a page which is not in the cache forces a CGI call, which generates the page and updates the cache.
Here's what I do to make this work:
ErrorDocument 404 /mywiki/nph-blah.cgi DirectoryIndex /mywiki/nph-blah.cgi/0 Options MultiViews
#!/bin/sh echo HTTP/1.0 200 OK cd /path/to/my/datafile WIKIT_BASE=http://<mysite>/mywiki/ export WIKIT_BASE WIKIT_CACHE=/path/to/mywiki export WIKIT_CACHE #WIKIT_CSS=http://url/of/my/style/sheet.css #export WIKIT_CSS # uncomment following as needed #WIKIT_DUMP=/path/to/mywikilogfile #export WIKIT_DUMP #WIKIT_HIST=/path/to/mywikihistdir #export WIKIT_HIST exec /path/to/tclkit wikit.kit mywikit.tkd
The "Options MultiViews" cause an access for page "123" to be satisfied when file "123.html" is present.
Hmmm... is WIKIT_CACHE really available?? It doesn't seem to work at all. Also, just a wee small thingy, can WIKIT_CACHE be /path/to/my/htdocs? Will that work? I generally do not want people to be able to poke their browsers into my cgi area ;^)
12nov02 jcw - Yes it is, that's how the Tclers' Wiki is set up. The trick is the redirect everything to a CGI. So what you do is create a dir just for the cache, make that the public one, i.e. the "real" public area, then redirect page misses to a CGI elsewhere, telling that CGI to update this area. When it does, the page will exist, i.e. not trigger an error from then on, hence be served statically. If you follow what I'm saying...
13dec2002 ps I wonder why the above .cgi has [echo HTTP/1.0 200 OK], my apache doesn't like it... It works fine without that statement.