Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

FormMail snag cgi

FormMail snag cgi

FormMail snag cgi

i want to hide the email address that a form is going to. so here's the readme file that explains how to do it but .. i can't figure it out
@recipients         - A list of Perl regular expression patterns that
                      determine who the script will allow mail to be sent
                      to in addition to those set in @allow_mail_to. This is
                      present only for compatibility with the original
                      formmail script.  We strongly advise against having
                      anything in @recipients as it's easy to make a mistake
                      with the regular expression syntax and turn your
                      formmail into an open SPAM relay.

                      There is an implicit $ at the end of the regular
                      expression, but you need to include the ^ if you want
                      it anchored at the start.  Note also that since '.' is
                      a regular expression metacharacter, you'll need to
                      escape it before using it in domain names.

                      If that last paragraph makes no sense to you then
                      please don't put anything in @recipients, stick to
                      using the less error prone @allow_mail_to.

%recipient_alias    - A hash for predefining a list of recipients in the
                      script, and then choosing between them using the
                      recipient form field, while keeping all the email
                      addresses out of the HTML so that they don't get
                      collected by address harvesters and sent junk email.

                      For example, suppose you have three forms on your
                      site, and you want each to submit to a different email
                      address and you want to keep the addresses hidden.
                      You might set up %recipient_alias like this:

                      %recipient_alias = (
                        '1' => 'one@your.domain',
                        '2' => 'two@your.domain',
                        '3' => 'three@your.domain',

                      In the HTML form that should submit to the recipient
                      'two@your.domain', you would then set the recipient

                      <input type="hidden" name="recipient" value="2" />

                      The recipients in %recipient_alias are automatically added
                      to the allowed recipients list, so there's no need to list
                      them all in @allow_mail_.
here's the code in FormMail.cgi that used. when i click submit it says internal error.
        @referers = ('scriptarchive.com','ottawa.ca');

# @recipients defines the e-mail addresses or domain names that e-mail can   #
# be sent to.  This must be filled in correctly to prevent SPAM and allow    #
# valid addresses to receive e-mail.  Read the documentation to find out how #
# this variable works!!!  It is EXTREMELY IMPORTANT.                         #
@recipients = ('^webmaster\@ottawa.ca');
# %recipient_alias = (
                       # '1' => 'webmaster@lottawa.ca',#
                        #'2' => 'two@your.domain',#
                        #'3' => 'three@your.domain',#

RE: FormMail snag cgi

maybe this:


# %recipient_alias = (
                       # '1' => 'webmaster@lottawa.ca',#
                        #'2' => 'two@your.domain',#
                        #'3' => 'three@your.domain',#

should be:


%recipient_alias = (
                       '1' => 'webmaster@lottawa.ca'

I am not sure, but give it a try and see if it does what you want.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close