Avatar of nsitedesigns
nsitedesigns
Flag for United States of America asked on

form isn't working is it missing a document

I inherited an old html site today.  All 3 forms listed below do not work.  

Contact
http://www.torginol.com/contact/

Sample request
http://www.torginol.com/samples/

Careers
http://www.torginol.com/company/careers/

When you try to complete the form you go to a 404 error page  http://www.torginol.com/cgi-sys/FormMail.cgi

Does this mean that there should be a directory called cgi-sys on the server and within that directory there should be a file called FormMail.cgi?   I don't deal with this kind a form alot.
Web Development* CGIHTMLScripting Languages

Avatar of undefined
Last Comment
nsitedesigns

8/22/2022 - Mon
SOLUTION
Ben Personick (Previously QCubed)

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Nicholas

CGI is very much old school - if you have access to a scripting language like PHP or .net then switch to that
CGI is more a legacy language at this point that is only maintained because they have to
HainKurt

do you have this folder

http://www.torginol.com/cgi-sys/

what files do you have here?

do you have required permission here / execute for example!
SOLUTION
Julian Hansen

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
nsitedesigns

ASKER
Thanks  for all the help everyone.  In answer to some of your questions, no, there was no folder on the server called cgi-sys.  Yes, I know it is antiquated.  The entire site is needs an update.  It is setup using tables and graphics with words rather than text, etc.  So many issues to deal with but right now, I need to find the quickest solution to fixing the form.  

Client called this morning.  They had spent hours on phone complaining to host about form no longer working.  Host got form to "work" but even though it appears to be sending the email the client isn't getting the email.  So now, I need to determine what email was setup to get the form.  I need to do some digging.  WIll keep you posted
Experts Exchange is like having an extremely knowledgeable team sitting and waiting for your call. Couldn't do my job half as well as I do without it!
James Murphy
nsitedesigns

ASKER
Was told my host, "the cPanel developers removed the FormMail.cgi script without notice or explanation. They left the formmail.pl script, so they changed the form action from cgi-sys/FormMail.cgi to cgi-sys/formmail.pl and you forms are working now."

I tried to open formmail.pl but there didn't appear to be any info on the file.  Where do I go to see what email these are supposedly being sent to?
Ben Personick (Previously QCubed)

When you say you tried to open formmail.pl, you did this on the server's OS?  (Don't browse it through the URL like we have to)

When I browse through the web browser I get the following Info (see screenshot) which means the .pl file simply cannot be empty, it is generating this text because there was no post with info on what to send.

FormMail.pl when done in a browser
nsitedesigns

ASKER
I tried opening it again and after a real long time it did finally show text.  My system must be running slow.  I changed the   @allow_mail_to     = qw(pattie@nsitedesigns.com); so it is now my email and I refilled out the form.  Still am not getting anything.  Am I missing something else I need to modify?

#!/usr/bin/perl -wT
#
# NMS FormMail Version 3.14m1
#

use strict;
use vars qw(
  $DEBUGGING $emulate_matts_code $secure %more_config
  $allow_empty_ref $max_recipients $mailprog @referers
  @allow_mail_to @recipients %recipient_alias
  @valid_ENV $date_fmt $style $send_confirmation_mail
  $confirmation_text $locale $charset $no_content
  $double_spacing $wrap_text $wrap_style $postmaster 
  $address_style
);

# PROGRAM INFORMATION
# -------------------
# FormMail.pl Version 3.14m1
#
# This program is licensed in the same way as Perl
# itself. You are free to choose between the GNU Public
# License <http://www.gnu.org/licenses/gpl.html>  or
# the Artistic License
# <http://www.perl.com/pub/a/language/misc/Artistic.html>
#
# For help on configuration or installation see the
# README file or the POD documentation at the end of
# this file.

# USER CONFIGURATION SECTION
# --------------------------
# Modify these to your own settings. You might have to
# contact your system administrator if you do not run
# your own web server. If the purpose of these
# parameters seems unclear, please see the README file.
#
BEGIN
{
  $DEBUGGING         = 1;
  $emulate_matts_code= 0;
  $secure            = 1;
  $allow_empty_ref   = 1;
  $max_recipients    = 5;
  $mailprog          = '/usr/lib/sendmail -oi -t';
  $postmaster        = '';
  @referers          = qw(dave.org.uk 209.207.222.64 localhost);
  @allow_mail_to     = qw(pattie@nsitedesigns.com);
  @recipients        = ();
  %recipient_alias   = ();
  @valid_ENV         = qw(REMOTE_HOST REMOTE_ADDR REMOTE_USER HTTP_USER_AGENT);
  $locale            = '';
  $charset           = 'iso-8859-1';
  $date_fmt          = '%A, %B %d, %Y at %H:%M:%S';
  $style             = '/css/nms.css';
  $no_content        = 0;
  $double_spacing    = 1;
  $wrap_text         = 0;
  $wrap_style        = 1;
  $address_style     = 0;
  $send_confirmation_mail = 0;
  $confirmation_text = <<'END_OF_CONFIRMATION';
From: you@your.com
Subject: form submission

Thank you for your form submission.

END_OF_CONFIRMATION

# You may need to uncomment the line below and adjust the path.
# use lib './lib';

# USER CUSTOMISATION SECTION
# --------------------------
# Place any custom code here



# USER CUSTOMISATION << END >>
# ----------------------------
# (no user serviceable parts beyond here)
}

use CGI::NMS::Script::FormMail;
use base qw(CGI::NMS::Script::FormMail);

use vars qw($script);
BEGIN {
  $script = __PACKAGE__->new(
     DEBUGGING              => $DEBUGGING,
     name_and_version       => 'NMS FormMail 3.14m1',
     emulate_matts_code     => $emulate_matts_code,
     secure                 => $secure,
     allow_empty_ref        => $allow_empty_ref,
     max_recipients         => $max_recipients,
     mailprog               => $mailprog,
     postmaster             => $postmaster,
     referers               => [@referers],
     allow_mail_to          => [@allow_mail_to],
     recipients             => [@recipients],
     recipient_alias        => {%recipient_alias},
     valid_ENV              => [@valid_ENV],
     locale                 => $locale,
     charset                => $charset,
     date_fmt               => $date_fmt,
     style                  => $style,
     no_content             => $no_content,
     double_spacing         => $double_spacing,
     wrap_text              => $wrap_text,
     wrap_style             => $wrap_style,
     send_confirmation_mail => $send_confirmation_mail,
     confirmation_text      => $confirmation_text,
     address_style          => $address_style,
     %more_config
  );
}

$script->request;

Open in new window

⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
SOLUTION
Ben Personick (Previously QCubed)

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
nsitedesigns

ASKER
Thanks for the info! I checked the server for the file mailform.cgi/mailform.pl  but there was none.  Where is this being pulled from?

I will test the Contact and Careers forms and see if they are processing correctly.
ASKER CERTIFIED SOLUTION
Ben Personick (Previously QCubed)

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Ben Personick (Previously QCubed)

it's the code in whatever is writing those pages that are setting the mailform.cgi versus pl.

  If those are not static pages then I have no way to determine how that code is generated, I don't have access to your back-end

If you need that sort of assistance you would probably do better to do a live/help or gig
nsitedesigns

ASKER
Think we have it figured out now.  Host told us to replace
/cgi-sys/FormMail.cgi

Open in new window

with
/cgi-sys/formmail.pl

Open in new window

on all form pages.   We can confirm that the Contact and Samples are now working.  The Careers form is being sent to another email which we cannot check at this time.

So, now I got this working (supposedly), client wants to move to new host.  He is mad at old host and they are only available via email.  WIth this kind of form, can I simply grab all folders in the cgi bin and move to new host?  Here is screenshot of files in cgi-bin directory

https://screencast.com/t/YH1R94EKNOKF
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
SOLUTION
HainKurt

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Ben Personick (Previously QCubed)

Hi Pattie,

  Yes, that's what I indicated above, but you said those pages didn;t have the info I shared with you.

  You should be able to transfer the content between hosts, that should be all you need, but if anything breaks it will tell you, just use that ti figure out what broke.

This is now officially at least a 2nd if not a 3rd question.

For further follow-up create new questions or since you seem to need a higher level of support open a live or gig.

Thanks,
Ben
SOLUTION
Ben Personick (Previously QCubed)

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
nsitedesigns

ASKER
Sometimes one question leads to another question and since support was already familiar with situation, I didn't think it was being out of line to ask related questions.  If i was, i apologize.  I will close question now.
HainKurt

I changed the recipient to my email an it said

Sorry I can't send to hainkurt@xxxxxxx.com. Is hainkurt@xxxxxxx.com on this server?

so, you should get emails... check your emails and spams...
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
nsitedesigns

ASKER
Huseyin, thank you for your additional testing.  I will try that.
Ben Personick (Previously QCubed)

Hey Pattie,

  Thats quite right, sometimes one question leads to another and it's easy to let the scope creep well beyond the original questions.  So most experts, myself included like to give a lot of leeway for the question's scope to increase so we can be as helpful as possible.

  We also have a responsibility to you to try to keep the questions from becoming too long and drawn out, so that you and other users looking up solutions can find concise Q&A sessions that don't drift too far hen they need to find the solution to their question.

  We also want to avoid the questions growing so long and containing so many sub-questions that they end up becoming abandoned and you don't get the support you need, which also ends up losing his content for you and others who come and search the site for solutions.

  I completely understand wanting to move forward on a question with people who already know what's going on too.  A good way of doing this is to open a question using the "Ask a related question" button on the right and note it in the chain, with a link to the next question too.

  I hope that is understandable. :)

Ben
nsitedesigns

ASKER
Thanks,  I didn't know about the related question button.
Your help has saved me hundreds of hours of internet surfing.
fblack61