home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Komputer 1998 May
/
Pcwk5b98.iso
/
WEBSERVE
/
PI3
/
PI3WEB.EXE
/
Pi3Docs
/
FEATURES
/
TESTSSI.SSI
< prev
Wrap
Text File
|
1997-10-06
|
8KB
|
183 lines
<HTML>
<TITLE>Pi3Web Feature Suite - SSI Test Page </TITLE>
<BODY BACKGROUND="/icons/Pi3Tile.gif"BGCOLOR="#FFFFFF">
<CENTER><H1>Pi3Web Feature Suite - SSI Test Page</H1></CENTER>
This is a page for testing server side includes.
<A NAME="__index">
<UL>
<LI><A HREF="#config">Configuration Directives</A>
<LI><A HREF="#vars">Standard Variables</A>
<LI><A HREF="#includes">File Inclusion</A>
<LI><A HREF="#exec">SSI CGI execution</A>
<LI><A HREF="#misc">Miscellanious</A>
<LI><A HREF="#pi3ext">Pi3Web Extension Directives</A>
</UL>
<BR>Return to <A HREF="index.htm">main features index</A>.<HR SIZE=1 NOSHADE>
<!--
Configuration Directives
--->
<A NAME="config">
<H2>Configuration Directives</H2>
The following directives don't yield a result but change the way other
directives are formatted, or change the error message.
<PRE>
<!--
111111111122222222223333333333444444444455555555556666666666777777777
0123456789012345678901234567890123456789012345678901234567890123456789012345678
-->
<B>Directive</B> <B>Action</B>
<HR SIZE=1 NOSHADE>
<!--#config errmsg="/** Error! **/"--> <!--#config errmsg="/** Error! **/"-->Change value given for SSI errors.
<!--#config timefmt="%c"--> <!--#config timefmt="%c"-->Set the format of dates and times (in strftime() format).
<!--#config sizefmt="%d"--> <!--#config sizefmt="%d"-->Set the format of sizes (in printf() format).
</PRE>
<P>Return to <A HREF="#__index">SSI index</A>.
<!--
Standard Variables
--->
<A NAME="vars">
<H2>Standard Variables</H2>
Simple variable substitution can be achieved using the 'echo' directive. This
is moderately efficient and should be used over more expensive mechanisms
(such as file inclusion and particularly CGI inclusion) where possible.
<PRE>
<!--
111111111122222222223333333333444444444455555555556666666666777777777
0123456789012345678901234567890123456789012345678901234567890123456789012345678
-->
<B>Directive</B> <B>Result</B>
<HR SIZE=1 NOSHADE>
<B><I>SSI specific variables</I></B>
<!--#echo var="DOCUMENT_NAME"--> <!--#echo var="DOCUMENT_NAME"-->
<!--#echo var="DOCUMENT_URI"--> <!--#echo var="DOCUMENT_URI"-->
<!--#echo var="DATE_GMT"--> <!--#echo var="DATE_GMT"-->
<!--#echo var="DATE_LOCAL"--> <!--#echo var="DATE_LOCAL"-->
<!--#echo var="LAST_MODIFIED"--> <!--#echo var="LAST_MODIFIED"-->
<B><I>Variables in common with CGI</I></B>
<!--#echo var="AUTH_TYPE"--> <!--#echo var="AUTH_TYPE"-->
<!--#echo var="CONTENT_LENGTH"--> <!--#echo var="CONTENT_LENGTH"-->
<!--#echo var="CONTENT_TYPE"--> <!--#echo var="CONTENT_TYPE"-->
<!--#echo var="PATH_INFO"--> <!--#echo var="PATH_INFO"-->
<!--#echo var="PATH_TRANSLATED"--> <!--#echo var="PATH_TRANSLATED"-->
<!--#echo var="QUERY_STRING"--> <!--#echo var="QUERY_STRING"-->
<!--#echo var="REMOTE_ADDR"--> <!--#echo var="REMOTE_ADDR"-->
<!--#echo var="REMOTE_HOST"--> <!--#echo var="REMOTE_HOST"-->
<!--#echo var="REMOTE_IDENT"--> <!--#echo var="REMOTE_IDENT"-->
<!--#echo var="REMOTE_USER"--> <!--#echo var="REMOTE_USER"-->
<!--#echo var="REQUEST_METHOD"--> <!--#echo var="REQUEST_METHOD"-->
<!--#echo var="SERVER_NAME"--> <!--#echo var="SERVER_NAME"-->
<!--#echo var="SERVER_PORT"--> <!--#echo var="SERVER_PORT"-->
<!--#echo var="SERVER_PROTOCOL"--> <!--#echo var="SERVER_PROTOCOL"-->
<!--#echo var="SERVER_SOFTWARE"--> <!--#echo var="SERVER_SOFTWARE"-->
<B><I>Extra header variables</I></B>
<!--#echo var="HTTP_ACCEPT"--> <!--#echo var="HTTP_ACCEPT"-->
<!--#echo var="HTTP_USER_AGENT"--> <!--#echo var="HTTP_USER_AGENT"-->
<!--#echo var="REFERER"--> <!--#echo var="REFERER"-->
<B><I>Non-standard additions</I></B>
<!--#echo var="ERROR_MESSAGES"--> <!--#echo var="ERROR_MESSAGES"-->
<!--#echo var="SERVER_ADMIN"--> <!--#echo var="SERVER_ADMIN"-->
<B><I>Test what happens for an unknown variable</I></B>
<!--#echo var="UNKNOWN"--> <!--#echo var="UNKNOWN"-->
</PRE>
<P>
Return to <A HREF="#__index">SSI index</A>.
<BR><HR SIZE=1 NOSHADE>
Return to <A HREF="index.htm">main features index</A>.
<!--
File inclusion
--->
<A NAME="includes">
<H2>File Inclusion</H2>
Server side includes allows files may be included into the main file. Other
directives to return the filesize (using the format optionally set by
the <CODE>#config sizefmt="..."</CODE> directive) or the files last modification date
(using the format optionally set by the <CODE>#config timefmt="..."</CODE>).
<PRE>
<!--
111111111122222222223333333333444444444455555555556666666666777777777
0123456789012345678901234567890123456789012345678901234567890123456789012345678
-->
<B>Directive</B> <B>Result</B>
<HR SIZE=1 NOSHADE>
<!--<B><I>SSI specific variables</I></B>-->
<!--#include virtual="/pidocs/features/include.txt"--> <!--#include virtual="/pidocs/features/include.txt"-->
<!--#include file="include.txt"--> <!--#include file="include.txt"-->
<!--#fsize virtual="/pidocs/features/include.txt"--> <!--#fsize virtual="/pidocs/features/include.txt"-->
<!--#fsize file="include.txt"--> <!--#fsize file="include.txt"-->
<!--#flastmod virtual="/pidocs/features/include.txt"--> <!--#flastmod virtual="/pidocs/features/include.txt"-->
<!--#flastmod file="include.txt"--> <!--#flastmod file="include.txt"-->
<HR SIZE=1 NOSHADE>
</PRE>
<P>Return to <A HREF="#__index">SSI index</A>.
<!--
SSI CGI Execution
--->
<A NAME="exec">
<H2>SSI CGI Execution</H2>
The output from CGI programs can also be included with SSI's by using the
'exec' directive.
<PRE>
<!--
111111111122222222223333333333444444444455555555556666666666777777777
0123456789012345678901234567890123456789012345678901234567890123456789012345678
-->
<B>Directive</B> <B>Action</B>
<!--#exec virtual="/cgi-bin/Echo.exe"--> <!--#exec virtual="/cgi-bin/Echo.exe"-->
<!--#exec file="../../cgi-bin/Echo.exe"--> <!--#exec file="../../cgi-bin/Echo.exe"-->
<!--#exec virtual="/cgi-bin/Hello.exe"--> <!--#exec virtual="/cgi-bin/Hello.exe"-->
<!--#exec file="../../cgi-bin/Hello.exe"--> <!--#exec file="../../cgi-bin/Hello.exe"-->
<HR SIZE=1 NOSHADE>
</PRE>
<P>Return to <A HREF="#__index">SSI index</A>.
<!--
Miscellanious
--->
<A NAME="misc">
<H2>Miscellanious</H2>
We do some miscellanious things also.
But they are not documented.
<PRE>
<!--
111111111122222222223333333333444444444455555555556666666666777777777
0123456789012345678901234567890123456789012345678901234567890123456789012345678
-->
<B>Directive</B> <B>Action</B>
<HR SIZE=1 NOSHADE>
</PRE>
<P>Return to <A HREF="#__index">SSI index</A>.
<!--
Pi3Web Extension Directives
--->
<A NAME="pi3ext">
<H2>Pi3Web Extension Directives</H2>
Pi3Expressions may be evaluated inline in server-side includes. This
offers greater flexibility over simpler variable expansion (using the
<CODE>#echo</CODE> directive). However where appropriate, simple
variable expressions should be used instead of Pi3Expression because of
the increased overhead of parsing and evaluating them.
<PRE>
<!--
111111111122222222223333333333444444444455555555556666666666777777777
0123456789012345678901234567890123456789012345678901234567890123456789012345678
-->
<B>Directive</B> <B>Result</B>
<!--#Pi3ext expr="(Process, thread) ($P/$k)"--> <!--#Pi3ext expr="(Process/thread) ($P/$k)"-->
<!--#Pi3ext expr="Debugging is &if($d,on,off)"--> <!--#Pi3ext expr="Debugging is &if($d,on,off)"-->
<HR SIZE=1 NOSHADE>
</PRE>
<P>Return to <A HREF="#__index">SSI index</A>.
<BR>Return to <A HREF="index.htm">main features index</A>.<HR SIZE=1 NOSHADE>