Re: [PBML] formmail is broken
- Hi David,
I changed the shebang line in the original Matt's script, but still got the config error.
Then I uploaded the NMS version after altering @referers, @recipients, and @allow_mail_to, and received the same error.
After that, I uploaded a virgin copy, but the error persisted.
Next, I looked up the error log. It indicated that my form code was truncated.
> [Tue Feb 14 08:57:46 2012] [error] [client 18.104.22.168] Unrecognized character \\x9C at formmail.pl line 752., referer: http://roxburyyouthworks.org/pages/email_test.htmlI couldn't see what was missing, so I inserted a new form. Now, finally, the form is working, but there is one thing I would like to change. When the user clicks SUBMIT, the result is a page made by formmail. What I want is to get my existing thankyou page: http://roxburyyouthworks.org/pages/thankyou.html.
> [Tue Feb 14 08:57:46 2012] [error] [client 22.214.171.124] Premature end of script headers: formmail.pl, referer: http://roxburyyouthworks.org/pages/email_test.html
> [Tue Feb 14 09:00:51 2012] [error] [client 126.96.36.199] Unrecognized character \\x9C at formmail.pl line 752., referer: http://roxburyyouthworks.org/pages/email_test.html
> [Tue Feb 14 09:00:51 2012] [error] [client 188.8.131.52] Premature end of script headers: formmail.pl, referer: http://roxburyyouthworks.org/pages/email_test.html
I tried placing the desired URL in each of the two possible lines below, but both incurred a misconfig error. Where can I add or alter the code to get my own thankyou page?
> # You may need to uncomment the line below and adjust the path.Thanks,
> # use lib './lib';
> # USER CUSTOMISATION SECTION
> # --------------------------
> # Place any custom code here
> On Tue, 14 Feb 2012 14:21:16 -0000Nicky McCatty
> "mirate" <talk@...> wrote:
> > This is a website I designed a few years ago. The CONTACT and EMAIL
> > SUBSCRIBE forms used to work, and they are broken.
> > When I click on the Submit button, I get a server error saying "The
> > server encountered an internal error or misconfiguration and was
> > unable to complete your request." I don't see what I'm doing wrong.
> Look in your web server's error_log or similar log file for clues as to
> what's going wrong.
> First, though, I'd very strongly suggest replacing that formmail script
> from Matt's Script Archive with a drop-in replacement from the nms
> project at: http://nms-cgi.sourceforge.net/
> The original script is badly written and insecure.
> As to why the original script isn't working, when I downloaded it I got
> extra characters before the shebang line - that's likely the problem.
> Grab yourself a drop-in replacement FormMail script from the nms
> project at the link above, and copy it into your cgi-bin directory,
> make minor configuration changes if required, and you should be good to
> If not, consult your server's error log for more information.
> David Precious ("bigpresh") <davidp@...>
> http://www.preshweb.co.uk/ www.preshweb.co.uk/twitter
> www.preshweb.co.uk/linkedin www.preshweb.co.uk/facebook
> www.preshweb.co.uk/cpan www.preshweb.co.uk/github
signify | Design
fusing image & information
talk@... | www.signifydesign.com
[Non-text portions of this message have been removed]