
Click above to get retro games delivered to your door ever month!
X-Hacker.org- ClipX.Lib v1.2 - <b>clipxopen()</b>
[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
ClipXOpen()
Required first call in each CGI program
---------------------------------------------------------------------
Syntax:
ClipXOpen( [<lDebug>] ) ---> lSuccess
Arguments:
[<lDebug>] is an optional logical value.
Returns: A logical value
Description:
REQUIRED FIRST X-Hacker.orgfunction call which:
Reads and parses form-variables and the server environmental variables.
Makes the FORM and SERVER variables available for other X-Hacker.orgfunctions.
ALWAYS TEST THE RETURN VALUE.
Failure to check the return value of "TRUE", may cause other ClipX
functions to fail.
[<lDebug>] is an optional logical value. X-Hacker.orgprograms can be tested
from the DOS prompt when this value is set to TRUE.
Input can be streamed from a file and output can be streamed to a file.
Example: MyCliX.exe < QryFIle.txt > Out.htm
. MyClix.exe must have been compiled with ClipXOpen( .t. ).
. QryFile.txt must contain a proper query string.
Example: hiddenField=Im Hidding&startMonth=01&startDay=01
. Out.htm is any file name. This file will contain the HTML page
that would have been sent to the web server. You can view it with
a text editor or from your browser. In order to make a more readable
file, use Cr() (carriage Return/line feed) after each HTML line
written.
Example: htmlBeg() ; Cr()
headBeg() : Cr()
...
htmlWrite( 'something' ) ;Cr()
htmlWrite( 'something else' + Chr(13)+Chr(10) )
cxOut( 'something else again' )
...
BodyEnd() : Cr()
htmlEnd() : Cr()
Files: Library is ClipX.Lib
Examples:
Example 1 Using ClipXOpen() to communicate with a WEB Server
if !ClipXOpen()
// Your termination routine or Quit
Quit
endif
Example 2 Using ClipXOpen() in debug mode. Running from a DOS prompt.
if !ClipXOpen( .t. )
// Your termination routine or Quit
Quit
endif
Files: Library is ClipX.Lib
See Also: ClipXClose()
Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson