swirl Guide to OmniMark 5   OmniMark home
docs home 
IndexConceptsTasksSyntaxLibrariesOMX VariablesErrors
 
Functions       Platforms  
  omcgi - CGI programming support    

The OmniMark CGI library contains one macro and two OmniMark functions to simplify writing CGI programs with OmniMark. The functions allow you to retrieve and decode CGI input data and CGI-related environment variables.

The CRLF macro allows you to easily use %13#%10#, instead of %n, to insert new lines in your CGI programs. Using the CRLF macro instead of %n ensures the portability of your code across platforms. You need to declare the #process-output stream as binary-mode so that all systems will properly interpret the %13#%10# newline sequence.

The OmniMark CGI library consists of a single include file, "omcgi.xin". This file contains the macro and function declarations.

You must also declare the #process-input stream as unbuffered. If you do not, on some systems your CGI program will hang. The #process-input is bound to standard input and used by your CGI program to receive POST data. This leaves #main-input free to receive a filename as an OmniMark command-line name if necessary.

The OmniMark CGI library requires OmniMark 5 or later.

You must include the following code at the beginning of your OmniMark CGI programs:

     declare #process-input has unbuffered
     declare #process-output has binary-mode
     declare #process-output has unbuffered

     include "omcgi.xin"

Functions
   cgiGetEnv
   cgiGetQuery
 
Platforms
   Digital UNIX (Alpha)
   HP/UX
   IBM AIX
   Linux (Intel)
   MS Windows 95/98
   MS Windows NT
   SGI IRIX
   SINIX
   Sun Solaris
 
----  

Top [ INDEX ] [ CONCEPTS ] [ TASKS ] [ SYNTAX ] [ LIBRARIES ] [ OMX ] [ OMX ] [ ERRORS ]

Generated: August 11, 2000 at 3:08:24 pm
If you have any comments about this section of the documentation, send email to docerrors@omnimark.com

Copyright © OmniMark Technologies Corporation, 1988-2000.