Simple Form Support v. 2.5

16 Nov. 94

Author: Mark Bracewell
[email protected]

Simple Form Support is a form handling script for Win HTTPD.
(requires vbrun300.dll)

It will handle forms in the following ways:

It will write (in html) to a file for storing form data, each entry is separated with


(<HR>), and you get to specify the filename, so it can be a private log file like c:\temp\submit.dat, or a public file like /htdocs/usertalk.htm.

Note: the file to which data is written must exist prior to running the script. If it does not exist, it will not be created and the script will return a 'file not found' error. Minimally, the file must include
<!--footer-->
on a line by itself.

Then it sends the client a confirmation of the submission or to any URL you specify.

Each form can have it's own section in the cgi_form.ini file so the "log" file and URL the client is sent to can be tailored to each form. The .ini file also allows you to specify whether to archive extra header information (the remote address of the client, type of browser, etc.) and whether to send the client to a new page or simply return a confirmation of the submission.


INSTALL
The executable, form2htm.exe, goes in your cgi-win dir.

cgi_form.ini goes in your windows directory.

Forms access cgi_form.exe this way:

<FORM METHOD="POST" ACTION="http://YOUR.DOMAIN/cgi-win/form2htm.exe/SECTION">

where 'SECTION' is the name of the section in cgi_form.ini that corresponds to that specific form.

The above example would look for [SECTION] as the configuration file for that form. here's what the .ini file looks like:


[SECTION]
;the file you want the form data appended to, don't forget the quotes
Archive="c:\temp\formsubm.htm"

;where you want the client to be sent after they submit the form
SendURL=/demo/

;add extra header info to archive file? (what you get depends on the browser)
ExtraHeaders=yes    (or 'Yes', anything else is the same as 'no')

;send only a confirmation of the submission?
Confirm=no    ('no' will send them to SendURL, 'yes' will send only a confirmation)

[AnotherSECTION]
Archive="c:\temp\data.txt"
SendURL=/demo/
ExtraHeaders=no  
Confirm=yes  

Notes:
Revision History:

1.0 initial release only archived the data and sent a confirmation.

2.0 added .ini file configuration (each form had an .ini file) and the option to send the client to a URL or a confirmation. Executable renamed cgi_form.exe (was comment.exe)

2.1 changed to one ,ini file with multiple sections

2.2 added footer capability and tidied up the docs

2.5 added plain text executable, changed names again


[email protected]