What happened to this site? And what's that frog about?

WIKIT_BASE ignored

F100 - Failure Feedback Forum 

Status: closed Severity: failure Category: Wikit Created: 2006-04-28 Updated: 2007-06-21

Just implemented CACHING for tclhttpd+wikit via Url_PrefixInstall Domainhandler, as documented in wiki.tcl.tk/4416. Nearly everything works as expected, with the following exception: The search-page seems to ignore WIKIT_BASE; so after navigating to it, all links are cgi-bin-Links again, so caching don't work afterwords...

And in conjunction with that: if I use caching (with tclhttpd), a search with text* (page contents) never returns... My Domainhandler is as follows:

  Url_PrefixInstall /wikiccsas [list wikiccsas {}]
  • Implementation des CACHINGS, siehe �wiki.tcl.tk/4416 proc wikiccsas {prefix sock suffix} { global Config upvar #0 Httpd$sock data set wikitCgiDir /cgi-bin/wiki/ccsas/wikitsh.exe; # noch variablisieren!
     # make suffix "relative"
     regsub {^/} $suffix {} suffix
     # redirect to "homepage" of wikit, if no "page"/suffix is given
     if {![string length $suffix]} {
         set suffix "0"
     }
     set cachefile [file join $Config(docRoot) $::env(WIKIT_CACHE) $suffix]
     # the url is http://xyz/0, but the cached file will be "0.html"
     # only append ".html" if request has no extension
     # (this avoids appending ".html" for other files in cache-dir, like
     # wikit.css
     if {[string equal [file extension $cachefile] ""]} {
         append cachefile ".html"
     }
     # check if file is in cache
     if {[file exists $cachefile]} {
         # file is in cache, so simply return cached file
         Httpd_ReturnFile $sock text/html $cachefile
     } else {
         # REDIRECT_URL must be set, because WIKIT checks it for caching
         # and tclhttpd doesn't set it itself
         set ::env(REDIRECT_URL) [file join $wikitCgiDir $suffix]
         set ::env(WIKIT_BASE)   [Httpd_SelfUrl /wikiccsas/]
         Httpd_Redirect $::env(REDIRECT_URL) $sock
     }
 }

2006-May-04 17:08:13 by anonymous:

Searches work ok if invoked directly via URL, e.g. .../seiten* CGI-script only hangs if using the search inputbox.

2006-May-05 08:45:19 by anonymous:

Meanwhile I've done further testing. It turned out that the problems with the seaches have nothing to do with CACHING... They occur only if using a WIKITSH.EXE directly as the CGI. If I use the other method (calling tclkit.exe wikit.kit through a small wrapper prog), everything works fine.

Hmmm, this is strange indeed. I can't think of an explanation -jcw



2006-04-28 mhoffman

Imported

2006-12-09 jcw

Copied from wikit cvstrac ticket #4

2007-06-21

(Changed: stat desc)

2007-06-21 jcw

(Changed: stat)

Add a comment:

Tip: add empty lines between paragraphs and indent lines to prevent reformatting.

Your name or initials:  

Powered by Mavrig