home *** CD-ROM | disk | FTP | other *** search
/ Internet Tools (CDV) / cdv_internet_tools.iso / KATALOG / ARCHIV / CGI / W21365.ZIP / README.TXT < prev    next >
Encoding:
Text File  |  1999-05-29  |  12.3 KB  |  348 lines

  1. CGIMailer for Windows 95/NT4.0
  2. Jun 1999 version 2.10
  3.  
  4. Author:
  5. Goran Boban
  6. gboban@cursor.hr
  7.  
  8.  
  9.     DISCLAIMER
  10.  
  11.     THIS SOFTWARE AND ALL THE ACCOMPANYING FILES ARE PROVIDED "AS IS" AND 
  12.     WITHOUT ANY WARRANTIES EXPRESSED OR IMPLIED INCLUDING BUT NOT LIMITED
  13.     TO IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 
  14.     PURPOSE. 
  15.  
  16.  
  17.  
  18.     LIMITATION OF LIABILITY
  19.  
  20.     AUTHOR SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE OR ANY
  21.     THIRD PARTY AS A RESULT OF USING SOFTWARE. IN NO EVENT WILL AUTHOR BE
  22.     LIABLE FOR ANY LOST REVENUE, PROFIT OR DATA, OR FOR DIRECT, INDIRECT,
  23.     SPECIAL, CONSEQUENTIAL, INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER  CAUSED
  24.     AND REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF THE USE OF OR
  25.     INABILITY TO USE SOFTWARE, EVEN IF AUTHOR HAS BEEN ADVISED OF THE
  26.     POSSIBILITY OF SUCH DAMAGES.      
  27.  
  28.  
  29.     1. Description
  30.     --------------
  31.  
  32. CGIMailer is an CGI (Common Gateway Interface) program wich will recive input from
  33. web form and send mail.
  34.  
  35. CGIMailer supports:
  36.     - Required variables
  37.     - Template based e-mail messages
  38.     - Template based response pages
  39.     - Customisable error reports
  40.     - File attachments
  41.  
  42. NOTE: There must be an SMTP server accessable from your server.
  43.  
  44.  
  45.  
  46.  
  47.     2. Installation
  48.     ---------------
  49.  
  50. To install CGIMailer just copy CGIMail.exe to cgi-bin directory of your web server or any
  51. other directory in wich your server will allow execute access. Please see your servers
  52. documentation for more information.
  53. (Note for IIS users - you will probablly want to install CGIMailer under your Scripts
  54. directory).
  55.  
  56. To install samples copy *.cf and *.htt files to the directory where CGIMailer can read them.
  57. Copy *.htm files to directory under your web root directory.
  58. Also, edit ACTION property of FORM tags in *.htm files and change TEMPLATE, MSGTEMPATE,
  59. SAVETOFILE variables in configuration files (*.cf) to reflect directories where you have
  60. placed files.
  61. PLEASE, READ THIS README FILE FIRST TO UNDERSTAND HOW THIS VARIABLES SHOULD BE SET.
  62.  
  63.  
  64.  
  65.     3. Using CGIMailer
  66.     ------------------
  67.  
  68. Please see history.txt for list of changes.
  69.  
  70. CGIMailer is controlled with configuration files (Every form that uses CGIMailer can
  71. have its own configuration file).
  72. You can setup following variables in configuration file:
  73.  
  74. TEMPLATE    is relative path (from CGIMail.exe) to template file used to create
  75.         response page if operation succeeds.
  76.         This variable is not required any more since you may specify LOCATION
  77.  
  78. LOCATION    is URL where CGIMailer will redirect users browser if operation succeeds.
  79.         This variable is used only if TEMPLATE variable is not present.
  80.  
  81. ERRTEMPLATE    relative path to template file if an error ocures. If this variable
  82.         is not set CGIMailer will display an built-in error message or redirect
  83.         to URL specified in ERRLOCATION.
  84.  
  85. ERRLOCATION    is URL where CGIMailer will redirect users browser if operation fails.
  86.         This variable is used only if ERRTEMPLATE variable is not present.
  87.  
  88. MSGTEMPLATE    template for creating mail message. If this variable is not set CGIMailer
  89.         will create message of following form:
  90.             VARIABLE1=VALUE1
  91.             VARIABLE2=VALUE2
  92.             ...
  93.         Where VARIABLE1, VARIABLE2 etc. are names of input fields in your web form.
  94.  
  95. SAVETOFILE    relative path (from CGIMail.exe) to file wich you want to use for saving
  96.         input. If this variable is not set, then CGIMailer will not try to save
  97.         input to file. There must be WRITE access specified for file.
  98.  
  99. DEBUG        If this variable is set to YES (DEBUG=YES) CGIMailer will send an text
  100.         response with transcription of comunication with SMTP server.
  101.         Othervise it will create response page based on file pointed in
  102.         TEMPLATE variable.
  103.  
  104. GATEWAY        Name of smtp server (smtp.server.com for example) to use for sending mail.
  105.         If this variable is not set CGIMailer will assume localhost.
  106.  
  107. PORT        Port number of SMTP service on SMTP server. By default it is 25.
  108.  
  109. FROM        E-mail address of sender. If this variable is not set CGIMailer will
  110.         assume an addres of form CURRENT_USER@NAME_OF_LOCAL_MACHINE.
  111.         You should set this variable in most cases.
  112.  
  113. TO        REQUIRED    E-mail addres (or list of addresses) of recipient(s).
  114.                 If this variable is not set CGIMailer will generate an
  115.                 error. E-mails have to be separated with space (" ").
  116.  
  117. CC        List of addresses to send carbon copy of message (displayed in Cc: field
  118.         of message).
  119.  
  120. BCC        List of addresses to send blind carbon copy of message. Addresses listed
  121.         in this line will not be listed in header of message.
  122.  
  123. SUBJECT        Subject of message.
  124.  
  125. TIMEOUT        Timeout (in seconds) for socket operations. Default is 300.
  126.  
  127. ATTACH        File to attach to mail message. There may be multiple lines containing
  128.         ATTACH.
  129.         All files attached to message are base64 encoded and marked as
  130.         "application/octet-stream".
  131.  
  132.  
  133. Name of configuration file can be passed to CGIMailer in two ways:
  134.  
  135.     - By setting SYS.CONFIGFILE (or SYS_CONFIGFILE) on Your form. Your caling HTML code
  136.     should look as follows:
  137.  
  138.         <FORM method=GET action="http://your.server/cgi-bin/cgimail.exe?">
  139.         <input type=hidden name=SYS.CONFIGFILE value="configfile.cf">
  140.  
  141.             . . .
  142.  
  143.         </FORM>
  144.  
  145.     - Or by passing name of configuration file as command-line parameter:
  146.  
  147.         <FORM method=POST action="http://your.server/cgi-bin/cgimail.exe?configfile.cf">
  148.  
  149.             . . .
  150.  
  151.         </FORM>
  152.  
  153.  
  154.  
  155. NOTE:    path to configuration file must be relative to directory where cgimail.exe is placed,
  156.     or absolute path (with drive letter).
  157.     Also use SYS.CONFIGFILE (SYS_CONFIGFILE) variable when using GET method.
  158.  
  159. You can also call CGIMailer from <A HREF> tag with
  160.  
  161.     <a href="http://your.server/cgi-bin/cgimail.exe?configurationfile.cf&var1=val1&...">
  162. or
  163.     <a href="http://your.server/cgi-bin/cgimail.exe?&SYS.CONFIGFILE=configfile.cf&var1=val1...">
  164.  
  165. or
  166.     <a href="http://your.server/cgi-bin/cgimail.exe?SYS.CONFIGFILE=configfile.cf&var1=val1...">
  167.  
  168.  
  169.     4. Variables
  170.     ------------
  171.  
  172. CGIMailer will proccess configuration file, response template file and message template file
  173. (if any) to check for variables to be replaced. Variables should appear in following format:
  174.  
  175.     <%VARIABLE_NAME%>
  176.  
  177.  
  178. CGIMailer recognises four types of variables:
  179.  
  180. - Required variables    Required variable names must start with "REQ." or "REQ_" (REQ.name
  181.             for example). When CGIMailer finds required variable in any of
  182.             following files: configuration file, response template file
  183.             or message template file, it will check if variable is passed
  184.             from form and if it contains any characters other than spaces.
  185.             If not so CGIMailer will generate an error. CGIMailer will also
  186.             check input from form for required variables.
  187.  
  188. - System variables    System variable names begin with "SYS." or "SYS_" prefix. Folowing
  189.             system variables are present in CGIMailer:
  190.  
  191.             SYS.YEAR(SYS_YEAR)         - current year.
  192.             SYS.MONTH(SYS_MONTH)        - current month.
  193.             SYS.DAY(SYS_DAY)        - day.
  194.             SYS.HOURES(SYS_HOURES)        - hour when CGIMailer is started.
  195.             SYS.MINUTES(SYS_MINUTES)    - minit when CGIMailer is started.
  196.             SYS.SECONDS(SYS_SECONDS)    - second when CGIMailer is started.
  197.             SYS.TEMPLATE(SYS_TEMPLATE)    - name of response template file.
  198.             SYS.LOCATION(SYS_LOCATION)    - succes URL (see LOCATION in
  199.                             configuration file).
  200.             SYS.ERRTEMPLATE(SYS_ERRTEMPLATE)- name of error template file.
  201.             SYS.ERRLOCATION(SYS_ERRLOCATION)- failure URL (see ERRLOCATION in
  202.                             configuration file).
  203.             SYS.MSGTEMPLATE(SYS_MSGTEMPLATE)- name of message template.
  204.             SYS.SAVETOFILE(SYS_SAVETOFILE)    - name of file used to save input.
  205.             SYS.MAILER(SYS_MAILER)        - name of mailer (defaults to: CGIMailer
  206.                             version 1.21)
  207.             SYS.INPUT(SYS_INPUT)        - preproccesed message wich is sent.
  208.             SYS.GATEWAY(SYS_GATEWAY)    - name of SMTP server.
  209.             SYS.HOST(SYS_HOST)        - name of local host (where CGIMailer
  210.                             is executed).
  211.             SYS.PORT(SYS_PORT)        - port number used to connect to SMTP
  212.                             service.
  213.             SYS.FROM(SYS_FROM)        - E-mail addres of sender.
  214.             SYS.TO(SYS_TO)            - E-mail(s) of recipient(s).
  215.             SYS.CC(SYS_CC)            - Addresses listed in Cc: field.
  216.             SYS.BCC(SYS_BCC)        - Bcc list of addresses.
  217.             SYS.SUBJECT(SYS_SUBJECT)    - Subject of message.
  218.             SYS.TIMEOUT(SYS_TIMEOUT)    - Timeout for socket operations in
  219.                             seconds.
  220.  
  221. - Environment variables    Environment variable names begin with "ENV." or "ENV_" prefix. CGIMailer
  222.             will replace every occurance of variable beginning with "ENV." prefix
  223.             with coresponding environment variable. For example occurance of ENV.TEMP
  224.             variable will be replaced with environment variable TEMP passed by OS
  225.             (contains name of default temporary directory on your system).
  226.  
  227. - Occurance of any other variable (not beginning with REQ., SYS. or ENV. prefix), will be simply
  228. replaced with its value.
  229.  
  230.  
  231.  
  232.  
  233.     5. Error template
  234.     -----------------
  235.  
  236. When an error occures (and if ERRTEMPLATE variable is set in configuration file) CGIMailer
  237. will use error template file to create an response to user. Error template file is
  238. an HTML document with directives of following form:
  239.  
  240.     <%SYS.errorNN%>
  241.  
  242. where NN is error code of error wich occures or one of keywords "default" or "end"
  243. For list of error codes generated by CGIMailer see errcodes.txt.
  244. When proccesing error template CGIMailer will create an HTML document from following
  245. parts of error template file:
  246.  
  247.     - beginning of document untill first <%SYS.errorNN%>, <%SYS.errordefault%>
  248.     <%SYS.errorend%> directive, or end of file if there is no any error directive.
  249.  
  250.     - section wich begins with <%SYS.errorNN%> directive (where NN is error code
  251.     of error generated by CGIMailer if such directive) or <%SYS.errordefault%>
  252.     directive if there is no an appropriate <%SYS.errorNN%> directive,
  253.     and ends with any other error directive or end of file if no error directives
  254.     are listed after this one.
  255.  
  256.     - section wich begins with <%SYS.errorend%> directive and ends with end of file.
  257.  
  258. For the complete listing of error codes see errcodes.txt
  259.  
  260.     6. Registration
  261.     ---------------
  262.  
  263. You have permission to use an unregistered copy of CGIMailer for
  264. period of 30 days for evaluation purposes only.
  265. If You continue to use CGIMailer after period of 30 days You have
  266. to register it.
  267. Also You have permission to distribute CGIMailer package under
  268. following conditions:
  269.  
  270.     - You have to distribute CGIMa130.zip package as it is without any changes. 
  271.     - You take no fee other than for distribution costs. 
  272.     - It must be clear that CGIMailer is shareware. 
  273.  
  274. CURRENTLY AN UNREGISTERED COPY OF CGIMAILER WILL ATTACH SHORT MESSAGE
  275. TO ALL CREATED PAGES.
  276.  
  277. To remove this messages You have to register. 
  278.  
  279. To register CGIMailer just follow these steps:
  280.  
  281.     - Obtain an registration key
  282.  
  283. If You are registered user of any version prior to 2.10 just use registration key you have
  284. (Upgrade is free for You).
  285.  
  286. If You are not an registered user of version prior to 2.10 You have to pay $15 as registration
  287. fee.
  288.  
  289. On-line registration is aviable via Register Now! service at:
  290.  
  291.     https://www.regnow.com/softsell/nph-softsell.cgi?item=1275-2
  292.  
  293. You can use Visa, Mastercard, American Express, or Discover card.
  294.  
  295. You can also send me money with mail to following address:
  296.  
  297.     Goran Boban
  298.     Zeleni trg 3, 10000 Zagreb
  299.     Croatia (Europe)
  300.  
  301. If You decide to send money with mail please send cache only. Also please contact me
  302. via e-mail before sending money.
  303.  
  304. Also be sure to send me following information
  305.  
  306. - Your first and last name (or company name)
  307. - E-mail address
  308. - Name of program you want to register (CGIMailer in this case)
  309.  
  310. BE SURE TO SEND AN E-MAIL ADDRESS SO I CAN SEND YOU A REGISTRATION KEY
  311.  
  312.  
  313.     - Register Your software using register.exe
  314. Register.exe utility is distributed within this package.
  315. By using register.exe You will disable messages which unregistered version of
  316. CGIMailer attaches to responses sent to user.
  317.  
  318. NOTE: For information on running register.exe see register.txt file.
  319.  
  320.  
  321.  
  322.     7. Bugs
  323.     -------
  324.  
  325.     PLEASE SEND BUG REPORTS to
  326.  
  327.         gboban@cursor.hr
  328.  
  329.     with:
  330.         CGIMail - bugs
  331.     in subject.
  332.  
  333.     Also feel free to contact me if you have any problems running or setting-up
  334.     CGIMailer or if you have any sugestions for future releases.
  335.  
  336.     IMPORTANT: When sending bug reports or questions please be sure to include
  337.     following information:
  338.  
  339.     - Program name    (CGIMailer)
  340.     - Version    (2.10)
  341.     - OS        (Win95/98/NT4.0)
  342.     - Web server name and version.
  343.     - What have You tryed to solve problem
  344.     - Any other information which You find relevant.
  345.  
  346.  
  347.  
  348.