Error processing request

Parameters

CONTENT_LENGTH0
REQUEST_METHODGET
REQUEST_URI/revision/CGI+script+for+directory+listing%2C+simple+posts+and+templates?V=32
QUERY_STRINGV=32
CONTENT_TYPE
DOCUMENT_URI/revision/CGI+script+for+directory+listing,+simple+posts+and+templates
DOCUMENT_ROOT/var/www/nikit/nikit/nginx/../docroot
SCGI1
SERVER_PROTOCOLHTTP/1.1
HTTPSon
REMOTE_ADDR172.70.179.141
REMOTE_PORT49598
SERVER_PORT4443
SERVER_NAMEwiki.tcl-lang.org
HTTP_HOSTwiki.tcl-lang.org
HTTP_CONNECTIONKeep-Alive
HTTP_ACCEPT_ENCODINGgzip, br
HTTP_X_FORWARDED_FOR18.222.193.123
HTTP_CF_RAY88d229a78e8e0293-ORD
HTTP_X_FORWARDED_PROTOhttps
HTTP_CF_VISITOR{"scheme":"https"}
HTTP_ACCEPT*/*
HTTP_USER_AGENTMozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; [email protected])
HTTP_REFERERhttp://tcl.wiki/revision/CGI+script+for+directory+listing%2C+simple+posts+and+templates?V=32
HTTP_CF_CONNECTING_IP18.222.193.123
HTTP_CDN_LOOPcloudflare
HTTP_CF_IPCOUNTRYUS

Body


Error

Unknow state transition: LINE -> END

-code

1

-level

0

-errorstack

INNER {returnImm {Unknow state transition: LINE -> END} {}} CALL {my render_wikit {CGI script for directory listing, simple posts and templates} {''[JM] 29 Dec 2012'' - When reading about [Templates and subst] on this wiki, I came across this web page [http://andy.junkdrome.org] and wanted to give it a try, on my Windows XP (and Ubuntu) PC.

For Windows: the apache installer can be found at [http://www.apachefriends.org/en/xampp.html] (it was installed under: C:\xampp)

These are the steps I have taken to setup this script and learn during that process (thanks [AMG]): 

1.- Copied the tcl script [http://andy.junkdrome.org/growth/data/site.tcl] to my cgi-bin folder.<<br>>
 Windows: C:\xampp\cgi-bin
 Ubuntu: /usr/lib/cgi-bin
2.- Copied the site.css (to my docroot folder) from [http://andy.junkdrome.org] in order to get the nice and simple style that you see there.<<br>>
3.- Created a .htaccess file on my docroot folder
 Windows: C:\xampp\htdocs
 Ubuntu: /var/www
with the following contents:
======none
# Enable URL rewriting.
RewriteEngine on

# Just let Apache send/process the file if it already exists.  This rule also
# prevents an infinite rewrite loop, since the rewrite maps to an existing file.
RewriteCond %{REQUEST_FILENAME} !-f

# Generate all directory listings, phony files, etc. with a script.
RewriteRule ^ /cgi-bin/site.tcl [L]

# Hide dotfiles.
<Files ~ "^\.">
   Order deny,allow
   Deny from all
</Files>
======
4.- Modified the site.tcl script to match my "site" (these are the few lines that I modified)
======none
# Configuration.
set ::docroot xampp/htdocs
set ::baseurl http://localhost
======
Of course, you should also modify the mail and timezone variables for your own page.<<br>>
5.- Finally, I just made a file called .desc (on my docroot folder) which contains simple lists which elements are:
    * a title
    * an "epoch" time-stamp,see: [clock seconds]
    * and HTML content
Here a sample content of such file:
======none
{title1 1356737274 "some content"}
{title2 1356737274 {some <a href="http://andy.junkdrome.org/">Andy</a> more content}}
{title3 1356737274 "some more content"}
{title4 1356737274 "and more content"}
{title5 1356737274 "some content"}
{title6 1356737274 "some content"}
{title7 1356737274 "some content"}
{title8 1356737274 "some content"}
{title9 1356737274 "some content"}
{titleA 1356737274 "some content"}
{titleB 1356737274 "some content"}
{titleC 1356737274 "some content"}
======
Key Paths on ubuntu:
%|Description|Path|%
&|Apache configuration|set a custom icon for folders |put an image file on that folder whose name is:|_MajaMaja_icon.jpg|&
&|DocumentRoot|/var/www|&
&|ScriptAlias|/usr/lib/cgi-bin|&
&|Tcl|/usr/bin/tclsh|&
======
Final Notes:
   * .htaccess and .desc files are getting listed on my Windows PC, on Unix though, [[[glob] *]] skips dotfiles, at least 8.5.2's [[glob]] does. (As [AMG] explained to me). This is not good, but at least, its access is still forbidden. (I Think you could modify the glob statement on the site.tcl script to omit such files)
   * I have not explored yet the templatized html feature included on the script, that is a "to be continued" kind of thing...
   * Also, you will have a slot with a missing image on top of the page, for your site's logo/banner
   * You cannot create a .desc or .htaccess from the file explorer GUI in windows, you can however, create the files from DOS and/or wish

[ImgAMGSiteCGI]

<<categories>> Template | Web | Internet} regexp2} CALL {my render {CGI script for directory listing, simple posts and templates} {''[JM] 29 Dec 2012'' - When reading about [Templates and subst] on this wiki, I came across this web page [http://andy.junkdrome.org] and wanted to give it a try, on my Windows XP (and Ubuntu) PC.

For Windows: the apache installer can be found at [http://www.apachefriends.org/en/xampp.html] (it was installed under: C:\xampp)

These are the steps I have taken to setup this script and learn during that process (thanks [AMG]): 

1.- Copied the tcl script [http://andy.junkdrome.org/growth/data/site.tcl] to my cgi-bin folder.<<br>>
 Windows: C:\xampp\cgi-bin
 Ubuntu: /usr/lib/cgi-bin
2.- Copied the site.css (to my docroot folder) from [http://andy.junkdrome.org] in order to get the nice and simple style that you see there.<<br>>
3.- Created a .htaccess file on my docroot folder
 Windows: C:\xampp\htdocs
 Ubuntu: /var/www
with the following contents:
======none
# Enable URL rewriting.
RewriteEngine on

# Just let Apache send/process the file if it already exists.  This rule also
# prevents an infinite rewrite loop, since the rewrite maps to an existing file.
RewriteCond %{REQUEST_FILENAME} !-f

# Generate all directory listings, phony files, etc. with a script.
RewriteRule ^ /cgi-bin/site.tcl [L]

# Hide dotfiles.
<Files ~ "^\.">
   Order deny,allow
   Deny from all
</Files>
======
4.- Modified the site.tcl script to match my "site" (these are the few lines that I modified)
======none
# Configuration.
set ::docroot xampp/htdocs
set ::baseurl http://localhost
======
Of course, you should also modify the mail and timezone variables for your own page.<<br>>
5.- Finally, I just made a file called .desc (on my docroot folder) which contains simple lists which elements are:
    * a title
    * an "epoch" time-stamp,see: [clock seconds]
    * and HTML content
Here a sample content of such file:
======none
{title1 1356737274 "some content"}
{title2 1356737274 {some <a href="http://andy.junkdrome.org/">Andy</a> more content}}
{title3 1356737274 "some more content"}
{title4 1356737274 "and more content"}
{title5 1356737274 "some content"}
{title6 1356737274 "some content"}
{title7 1356737274 "some content"}
{title8 1356737274 "some content"}
{title9 1356737274 "some content"}
{titleA 1356737274 "some content"}
{titleB 1356737274 "some content"}
{titleC 1356737274 "some content"}
======
Key Paths on ubuntu:
%|Description|Path|%
&|Apache configuration|set a custom icon for folders |put an image file on that folder whose name is:|_MajaMaja_icon.jpg|&
&|DocumentRoot|/var/www|&
&|ScriptAlias|/usr/lib/cgi-bin|&
&|Tcl|/usr/bin/tclsh|&
======
Final Notes:
   * .htaccess and .desc files are getting listed on my Windows PC, on Unix though, [[[glob] *]] skips dotfiles, at least 8.5.2's [[glob]] does. (As [AMG] explained to me). This is not good, but at least, its access is still forbidden. (I Think you could modify the glob statement on the site.tcl script to omit such files)
   * I have not explored yet the templatized html feature included on the script, that is a "to be continued" kind of thing...
   * Also, you will have a slot with a missing image on top of the page, for your site's logo/banner
   * You cannot create a .desc or .htaccess from the file explorer GUI in windows, you can however, create the files from DOS and/or wish

[ImgAMGSiteCGI]

<<categories>> Template | Web | Internet}} CALL {my revision {CGI script for directory listing, simple posts and templates}} CALL {::oo::Obj641296 process revision/CGI+script+for+directory+listing%2C+simple+posts+and+templates} CALL {::oo::Obj641294 process}

-errorcode

NONE

-errorinfo

Unknow state transition: LINE -> END
    while executing
"error $msg"
    (class "::Wiki" method "render_wikit" line 6)
    invoked from within
"my render_$default_markup $N $C $mkup_rendering_engine"
    (class "::Wiki" method "render" line 8)
    invoked from within
"my render $name $C"
    (class "::Wiki" method "revision" line 31)
    invoked from within
"my revision $page"
    (class "::Wiki" method "process" line 56)
    invoked from within
"$server process [string trim $uri /]"

-errorline

4