From d833b799cd708b10cde5d13af89d42f0b4d95758 Mon Sep 17 00:00:00 2001
From: Rich Bowen
-
bytes
for a count in bytes, or abbrev
for a count
in Kb or Mb as appropriate.strftime(3)
library routine when printing
@@ -133,17 +133,18 @@
(none)
. Any dates printed are subject to the
currently configured timefmt
. Attributes:
-
-
For example:
+ +<!--#exec cgi="/cgi-bin/example.cgi" -->
+
If the script returns a Location: header instead of output, then this will be translated into an HTML anchor.
-The include virtual
element should be
- used in preference to exec cgi
.
The include
+ virtual
element should be
+ used in preference to exec cgi
. In particular,
+ if you need to pass additional arguments to a CGI program,
+ using the query string, this cannot be done with exec
+ cgi
, but can be done with include
+ virtual
, as shown here:
<!--#include virtual="/cgi-bin/example.cgi?argument=value" -->
- /bin/sh
. The include variables are available
- to the command.The server will execute the given string using
+ /bin/sh
. The include variables are available
+ to the command, in addition to the usual set of CGI
+ variables.
The use of #include
+ virtual
is almost always
+ prefered to using either #exec cgi
or #exec
+ cmd
. The former (#include virtual
) used the
+ standard Apache sub-request mechanism to include files or
+ scripts. It is much better tested and maintained.
In addition, on some platforms, like Win32, and on unix
+ when using suexec, you cannot pass arguments to a command in
+ an exec
directive, or otherwise include spaces in
+ the command. Thus, while the following will work under a
+ non-suexec configuration on unix, it will not produce the
+ desired result under Win32, or when running suexec:
<!--#exec cmd="perl /path/to/perlscript arg1 arg2" -->
+
+ ../
, nor can it be an absolute path.
+ Therefore, you cannot include files that are outside of the
+ document root, or above the current document in the directory
+ structure.
The virtual
attribute should always be used
in preference to this one.The value is a (%-encoded) URL relative to the current document being parsed. The URL cannot contain a scheme or hostname, only a path and an optional query string. If it does not begin with a slash (/) then it is - taken to be relative to the current document.
A URL is constructed from the attribute, and the output the server would return if the URL were accessed by the client is included in the parsed output. Thus included files can - be nested. + be nested.
+ +If the specified URL is a CGI program, the program will + be executed and its output inserted in place of the directive + in the parsed file. You may include a query string in a CGI + url:
+ +<!--#include virtual="/cgi-bin/example.cgi?argument=value" -->
+
+ include virtual
should be used in preference
+ to exec cgi
to include the output of CGI
+ programs into an HTML document.
+
This prints out a listing of all existing variables and
their values. Starting with Apache 1.3.12, special characters
are entity encoded (see the echo
element for details)
- before being output. No attributes.
<!--#printenv -->
For example:
-<!--#printenv -->
The printenv element is available only in + Apache 1.2 and above.
+
For example: <!--#set var="category" value="help"
- -->
-
The set element is available only in + Apache 1.2 and above.
+ -echo
command, for
if
and elif
, and to any program
--
2.50.1