Include Tests

This file is: /opt/htbase/KITBASE/SERVER/STANDARD.kit/bin/../htdocs/include.shtml

The server supports server side command processing, generally known as server-side includes. The general HTML syntax is:

<!--#command arg=value arg=value -->

The commands supported are:

include
Include another file. The file is named with a virtual= or file= parameter. The virtual path is relative to the document root. The file path is relative to the current document.
echo
Echo the value of an environment variable. See the Environment section below for the variables the server can set.
fsize
Return the size of a file. The file is named with a virtual= or file= parameter. The virtual path is relative to the document root. The file path is relative to the current document.
flastmod
Return the modify time of a file. The file is named with a virtual= or file= parameter. The virtual path is relative to the document root. The file path is relative to the current document.
exec
Execute the cmd= parameter and insert the results.

Environment

Get these with
<!--#echo var=varname -->

Exec tests

This should be the contents of /etc/motd, or a comment containing an error if it does not exist.

NetBSD 7.99.1 (TRAFALGAR) #0: Fri Aug 19 14:16:57 UTC 2016

Welcome to NetBSD!

There should be a comment following this that complains about a missing /xyzzy file, (unless you have one!)

More stuff

Below is an errant include that accidentally includes itself! The include processor limits the include depth to work around bugs like this.


Standard Footer
Standard Footer
Standard Footer
Standard Footer
Standard Footer
Standard Footer
Standard Footer
Standard Footer
Standard Footer
Standard Footer