Welcome to the Tectite Forums! You can download and get support for our free PHP FormMail (form processor) and other free software.
I just uploaded the formmail.php and the sampleform.html and I tried to use it...
this is the error message that i received...
An error occurred while processing the form .
Please contact us directly since this form is not working .
We apologize for any inconvenience this error may have caused. Your form submission was processed by (7.04), available from www.tectite.com.
what do you think is the error?
I believe these are the changes i have made
formmail.php
define("abs","^[-a-z0-9.]+"); // the '^' is an important security feature!
$TARGET_EMAIL = array(abs."@absabs.us$");
my email address is abs@absabs.us
sampleform.html
<!-- STEP 1: Put the full URL to formmail.php on your website in the 'action' value. -->
<form method="post" action="http://houckremodeling.com/formmail.php" name="SampleForm">
<input type="hidden" name="env_report" value="REMOTE_HOST,REMOTE_ADDR,HTTP_USER_AGENT,AUTH_TYPE,REMOTE_USER">
<!-- STEP 2: Put your email address in the 'recipients' value.
Note that you also have to allow this email address in the
$TARGET_EMAIL setting within formmail.php!
-->
<input type="hidden" name="recipients" value="abs@absabs.us" />
<!-- STEP 3: Specify required fields in the 'required' value -->
<input type="hidden" name="required" value="email:Your email address,realname:Your name" />
<!-- STEP 4: Put your subject line in the 'subject' value. -->
<input type="hidden" name="subject" value="Sample FormMail Testing" />
<table border="1" cellspacing="5%">
<tr>
<td>
<p>Please enter your name:</p>
</td>
<td><input type="text" name="required" />
</td>
</tr>
<tr>
<td>
<p>Please enter your email address:</p>
</td>
<td><input type="text" name="required" />
</td>
</tr>
Do you think I have missed out something?
Last edited by abs; 09-Jan-2006 at 05:05 PM.
em, yep.
first to the formmail.php file:
this line isn't recommended to be modified, set it back to original condition as below:
furthermore the TARGET_EMAIL has to look like this in your case:Code:define("EMAIL_NAME","^[-a-z0-9.]+"); // the '^' is an important security feature!
and it's recommended to set the DEF_ALERT, in your case i suggest:Code:$TARGET_EMAIL = array("^abs@absabs\.us$");
(set it to the email address that will be sent any alert messages - such as errors - from the script)Code:define("DEF_ALERT","abs@absabs.us");
second to the sampleform.html file:
it looks quite good, except that you haven't to change realname and email to required in your input fields for name and email address. to get it working adjust it this way:
that it should be.Code:<table border="1" cellspacing="5%"> <tr> <td> <p>Please enter your name:</p> </td> <td><input type="text" name="realname" /> </td> </tr> <tr> <td> <p>Please enter your email address:</p> </td> <td><input type="text" name="email" /> </td> </tr>
best, erik
I am getting a new error
From formmail.php,Parse error: parse error in /home/httpd/vhosts/houckremodeling.com/httpdocs/formmail.php on line 6964
The last line is line 6984// handle type attribute first
$s_pat = '/(<\s*input[^>]*type="(?:radio|checkbox)"[^>]*name="';
$s_pat .= preg_quote($s_name,"/");
$s_pat .= '"[^>]*value="';
$s_pat .= preg_quote($s_value,"/");
$s_pat .= '")([^>]*?)(\s*\/\s*)?>';
$s_pat .= '/ims';
$s_buf = preg_replace($s_pat,'$1$2 checked="checked" $3>',$s_buf);
Hi,
The last thing you did to formmail.php (editing it or uploading it) has corrupted it.
You need to download formmail.php again, and reconfigure it using a simple program like Windows Notepad.
You need to upload using a program you know will not damage the contents of the file.
Russell Robinson - Author of Tectite FormMail and FormMailDecoder
http://www.tectite.com/
It worked.
But I got a second email which gave this
what does it mean? How do I stop error messages?To: abs@absabs.us
From: FormMail@houckremodeling.com
The following error occurred in FormMail :
Unable to create check file "/tmp/fmf8855b.txt": failed to open stream: No such file or directory
contact: 'Y'
colors: 'yellow'
vehicles: 'Truck'
mesg: 'dsfa'
Hi,
This error means that PHP is not configured properly on your server. FormMail is trying to create a temporary file and PHP is configured to create temporary files in a place that doesn't exist (called "/tmp")!
The correct solution is to get your hosting provider to fix the PHP configuration. Temporary files are important for many PHP scripts.
You can workaround this by telling FormMail not to check for a new version...
Look for:
and change it to:PHP Code:
define("CHECK_FOR_NEW_VERSION",true);
PHP Code:
define("CHECK_FOR_NEW_VERSION",false);
Russell Robinson - Author of Tectite FormMail and FormMailDecoder
http://www.tectite.com/
Everything is working great now. But how do I redirect it to a different page after form submission...
I used thisit didnt work....<input type="hidden" name="redirect" value="http://houckremodeling.com/thanks.html">
any suggestions?
I am the host. I lease the server. So, where do I create these tmp folder?
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks