Email.cgi version 1.0

  1. Introduction and version
  2. System requirements and installation
  3. Error messages

Introduction

Email.cgi is a CGI script to be used on MacHTTP servers for the purposes of sending email from WWW browsers who are not mailto-capable. In other words, it allows you, as a WWW systems administrator to allow people to send email messages from your server without the need of your users to have WWW clients who understand the email protocol. At the present time, this includes most versions of Mosaic, Cello, as well as MacWeb.

The current version of email.cgi is 1.0. and is available at ftp://ftp.lib.ncsu.edu/pub/software/mac/email-cgi.hqx.

System requirements and installation

Email.cgi requires:

Email.cgi also requires a forms-capable WWW browser at the client end.

The email.cgi AppleScript itself requires no configuration, but if you do happen to edit it, make sure you save it as an application that stays open and never shows a startup screen.

All the configuration for email.cgi lies in the form calling email.cgi. Below is a generic, but valid form for sending commands to email.cgi:

<html>
<head>
<title>Send a message to Eric Lease Morgan</title>
</head>

<body>
<H2>Send a message to Eric Lease Morgan (eric_morgan@ncsu.edu)</H2>
<FORM METHOD="POST" ACTION="http://emorgan.lib.ncsu.edu/email.cgi">

<INPUT TYPE="hidden" NAME="recipient" VALUE="eric_morgan@ncsu.edu">
<INPUT TYPE="hidden" NAME="mailer" VALUE="mail-relay.ncsu.edu">

What is your name?<BR>
<INPUT TYPE="text" NAME="user" SIZE="40" MAXLENGTH="40"><P>

What is your email address<BR>
<INPUT TYPE="text" NAME="address" SIZE="40" MAXLENGTH="40"><P>

What is the subject of your message<BR>
<INPUT TYPE="text" NAME="subject" SIZE="40" MAXLENGTH="40"><P>

What do you want to say?<BR>
<TEXTAREA NAME="message" ROWS=6 COLS=40></TEXTAREA><P>
<INPUT TYPE="Submit" VALUE="Send the message"> <INPUT TYPE="reset" VALUE="Reset">
</FORM>

</body>
</html>

Here is how to edit this generic form to meet your needs:
  1. Edit the title to anything you want.
  2. Change the first header to anything you want.
  3. Edit the ACTION field of the FORM line to reflect the URL of your copy of email.cgi.
  4. Edit the VALUE field of the first INPUT TYPE to reflect the email address whom you want to recieve the mail
  5. Edit the VALUE field of the second INPUT TYPE to reflect the Internet address of computer you know can forward email.
  6. Edit anything else you like, but don't change the contents of any of the NAME fields!

After editing your form, save it, and point to it via another HTML document. For example, if my Macintosh server is up and running, then you can send me mail at eric_morgan@ncsu.edu.

If all works well, you should get back some feedback telling you the message has been queued for delivery. Otherwise, you will recieve an error message.

Error messages

Right now, there is only one error message: Missing email element(s).

If this happens, then one of two thing occured. First, you may not have entered text into all the fields of the form (name, address, subject, and message). You must complete all the fields.

If you have completed all the fields, and you still get this error, then the form you are using has been misconfigured, and more than likely, the NAME fields have been changed. If this is the case, then, ironically, you must contact the author of the page and notifiy them of the broken form.


This page is maintained by Eric Lease Morgan (eric_morgan@ncsu.edu), and it was last modified November 2, 1994.

Go to library's home page. Go to NCSU's home page.