1 .TH ssi 8 "18 October 1995"
3 ssi - server-side-includes CGI program
8 This is an external CGI program that gives you the same functionality
9 as the built-in server-side-includes feature in some HTTP daemons.
10 It is written for use with thttpd(8), but should be easy to adapt
13 To use this program, first make sure it is installed in your server's
14 CGI area, and that CGI is enabled.
15 Then set up your URLs with the path to the document you want parsed
17 That's the part of the URL that comes after the CGI program name.
18 For example, if the URL to this program is:
20 http://www.acme.com/cgi-bin/ssi
22 and the url for your document is:
24 http://www.acme.com/users/wecoyote/doc.html
26 then the compound URL that gives you the document filtered through the
29 http://www.acme.com/cgi-bin/ssi/users/wecoyote/doc.html
32 The format description below is adapted from
33 http://hoohoo.ncsa.uiuc.edu/docs/tutorials/includes.html
36 All directives are formatted as SGML comments within the document.
37 This is in case the document should ever find itself in the client's
39 Each directive has the following format:
41 <!--#command tag1="value1" tag2="value2" -->
43 Each command takes different arguments, most only accept one tag at a time.
44 Here is a breakdown of the commands and their associated tags:
47 The config directive controls various aspects of the file parsing.
48 There are two valid tags:
51 gives the server a new format to use when providing dates.
52 This is a string compatible with the strftime library call.
55 determines the formatting to be used when displaying the
57 Valid choices are bytes, for a formatted byte count
58 (formatted as 1,234,567), or abbrev for an abbreviated version
59 displaying the number of kilobytes or megabytes the file occupies.
62 Inserts the text of another document into the parsed document.
63 The inserted file is parsed recursively, so it can contain
64 server-side-include directives too.
65 This command accepts two tags:
68 Gives a virtual path to a document on the server.
71 Gives a pathname relative to the current directory. ../ cannot
72 be used in this pathname, nor can absolute paths be used.
75 Prints the value of one of the include variables (defined below).
76 Any dates are printed subject to the currently configured timefmt.
77 The only valid tag to this command is var, whose value is the name of the
78 variable you wish to echo.
81 prints the size of the specified file,
82 subject to the sizefmt parameter to the config command.
83 Valid tags are the same as with the include command.
86 prints the last modification date of the specified file, subject
87 to the formatting preference given by the timefmt parameter to config.
88 Valid tags are the same as with the include command.
91 A number of variables are made available to parsed documents.
93 the CGI variable set, the following variables are made available:
99 The virtual path to this document (such as /~robm/foo.shtml).
101 .BR QUERY_STRING_UNESCAPED :
102 The unescaped version of any search query the client sent.
105 The current date, local time zone.
106 Subject to the timefmt parameter to the config command.
109 Same as DATE_LOCAL but in Greenwich mean time.
112 The last modification date of the current document.
113 Subject to timefmt like the others.
114 .SH "BUGS / DEFICIENCIES"
116 Does not implement the "exec" directive.
117 Actually, I consider this neither a bug nor a deficiency, but some may.
119 thttpd(8), strftime(3)
121 Copyright © 1995 by Jef Poskanzer <jef@mail.acme.com>.
123 .\" Redistribution and use in source and binary forms, with or without
124 .\" modification, are permitted provided that the following conditions
126 .\" 1. Redistributions of source code must retain the above copyright
127 .\" notice, this list of conditions and the following disclaimer.
128 .\" 2. Redistributions in binary form must reproduce the above copyright
129 .\" notice, this list of conditions and the following disclaimer in the
130 .\" documentation and/or other materials provided with the distribution.
132 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
133 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
134 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
135 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
136 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
137 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
138 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
139 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
140 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
141 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF