[ zurück ]

Delphi CGI Component Package, Version 1.2



INTRODUCTION

This package consists of three Delphi components and one type:

   * TCGI, the core component, allows Delphi applications to
     interact with information servers (primarily World Wide Web
     servers), processing input and generating output on the fly.

   * TCGIDlg, a dialog box component which aids in understanding
     and debugging CGI applications.

   * TTupleList, a descendant of TStringList, which allows easy
     access to data read in from .INI files, or any other key/value
     format.

   * TTupleGrid, a descendant of TStringGrid, which adds methods
     for displaying key/value pairs from a TTupleList.

TTupleList and TTupleGrid are included because they are used
extensively in the TCGI and TCGIDlg components.  They may be
useful in other applications as well.  They are contained in the
TUPLES unit.

This release has been tested with Win-httpd 1.4 (for Windows 3.1)
and WebSite (for Windows 95 & NT).  Win-httpd is available as
shareware (see http://www.city.net/win-httpd/).  WebSite is available
from O'Reilly and Associates (see http://website.ora.com/ for
features and ordering information).

Currently planned enhancements/add-ons include:

   * Execution templates, for greater flexibility in server support.
   * An HTML component, which will link to the CGI component and
     assist in outputting HTML tags, tables, and other markup.

INSTALLATION

To install, unzip the ZIP file using the -d option (to preserve
directory structure).  Start Delphi, choose Options|Install
Components..., click Add..., then Browse, and select CGIREG.DCU.
The CGI and CGIDlg components will be added to the Samples pallette.

If you wish to install the TTupleGrid on its own, select TUPLES.DCU
*before* CGIREG.DCU.  This will allow the TTupleGrid to remain
installed if you remove TCGI and TCGIDlg at a later time.

To install the context-sensitive help, move the CGI.HLP file to your
\DELPHI\BIN directory, and the CGI.KWF file to \DELPHI\HELP.  Run
Delphi's HelpInst utility.  Choose File|Open.  Select
\DELPHI\BIN\DELPHI.HDX.  Click the + icon, and select
\DELPHI\HELP\CGI.KWF.  Then choose File|Save, and exit.  The CGI
context-sensitive help is now integrated with the Delphi help system.

USE

Just place the CGI component on the main form of your application.
When the application is run by the information server (or as a
standalone app with the correct command line parameters), the CGI
component will automatically load all of the relevant data and open
the output file for your results.  See the help file for details.

For a complete description of how CGI applications interact with Web
servers, including a description of the command line, please refer
to the Windows CGI 1.2 interface specification (available at
http://website.ora.com/wsdocs/32demo/windows-cgi.html).


DEMOS

This ZIP file contains two demo programs, both of which are based on
Bob Denny's CGI demo for Visual Basic.  The only difference between
them is that one of them uses a form, while the other saves almost
70K by going formless.  Formless programming in Delphi is a little
trickier, but not too bad.  These demos won't run without the proper
command line and .ini file, so you must either set them up to be
executed by a Web server, or create an .ini file manually and fake
the parameters.  This should be pretty easy to figure out from the
CGI spec.  Admittedly, this makes it more difficult for people who
aren't running Web servers to write and test CGI apps, but the
shareware Win-httpd is readily available and makes the process much
easier.


VERSION HISTORY

1.2 - 9/14/95
-------------
* Separated TTupleList and TTupleGrid into the Tuples unit.
* Added TTupleList.ParseKeys method for splitting logical
  path info into key/value pairs.
* Removed Output page from TCGIDlg due to problems with
  string lengths and unpredictable output types.

1.1 - 8/1/95
------------
* Fixed GPF problem in TCGIDlg component.
* Fixed PIZZAD.DPR demo program.

1.0 - 7/18/95
-------------
* Initial Release.


LICENSE & REGISTRATION

Good news!  It's free!  However, if you appreciate the effort, you
might reward me by sending me a postcard.  It's just a nice reminder
that people are paying attention, and it helps prove to my boss that
I'm not a complete waste of salary and benefits.  Plus, it's a cool
way to see the world while I'm chained to my desk.  Send 'em to:

   Cool CGI Component
   Michael B. Klein
   c/o Washington Publishing Company
   806 W. Diamond Ave., Suite 400
   Gaithersburg, MD  20878

I retain full copyright.  You may use the TCGI and TCGIDlg
components in your compiled programs and DLLs royalty free, but you
may not distribute for monetary gain any of the source code,
documentation, example programs, or compiled units within this
package without my written permission and copyright notice.

If you have any questions, feel free to e-mail me:

   CompuServe: 74323,3555
   Internet: mbk&64#;baldrick&46#;com

Thanks for your interest, and enjoy!

[ Seitenanfang ] [ Windows-CGI ]

J. Hummel,   Apr. 1997