I'm not using an .ini file.
Just to confirm, I tested the sampleform on another site and it works, but there was no error handling on it. So this means it does work on my host, but for some reason its not when I am using error handling.
Cheers
m
Welcome to the Tectite Forums! You can download and get support for our free PHP FormMail (form processor) and other free software.
Are you using an ini file by any chance?
ginger
I'm not using an .ini file.
Just to confirm, I tested the sampleform on another site and it works, but there was no error handling on it. So this means it does work on my host, but for some reason its not when I am using error handling.
Cheers
m
The only thing I can see on your form is that you have different values for the "id" and "name" for the "realname" and "message" fields.
You might try making those the same and see if it makes a difference.
ginger
Did you try the sample form provided by tectite on another site, or did you test the form you've shown here (same exact code except for advanced error handling) on another site?
Also, did you set $TARGET_URLS in both scripts?
ginger
Last edited by ginger23; 21-Jul-2008 at 09:04 PM.
Hi.
Would you believe it, my host turned PHP safe mode off and it seems to be working. The one we were discussing is anyway.
My last form to get working is more of a HTML form issue I think.
I am getting the following error email:
The form fields are:Code:The following error occurred in FormMail : Template "contacttemplate.html" caused the following errors : "sampletype" is not a field submitted from the form "ifother" is not a field submitted from the form "keepinformed" is not a field submitted from the form
I wonder if I need to format these fields differently so they are accepted.HTML Code:<tr> <td height="32"> </td> <td><span class="style6"> <input name="keepinformed" type="checkbox" id="keepinformed" value="send info" /> Please keep me up-to-date about Warmawood <label> </label> </span> <span class="style9"> <label> </label> </span><span class="style7"> <label></label> </span> <label></label></td> </tr> <tr> <td height="40" class="formText"><p class="style15">REQUEST SAMPLES<br /> <br /> (CTRL-click to choose more than one)</p> </td> <td class="formText"><p> <label></label> <label> <select name="sampletype" size="5" multiple="multiple" id="sampletype"> <option value="Natural_Un_Finished">Natural Un-Finished</option> <option value="Natural_Pre_Finished">Natural Pre-Finished</option> <option value="Stained">Stained</option> <option value="Distressed">Distressed</option> <option value="Distressed_and_Fumed">Distressed & Fumed</option> <option value="Distressed_and_Stained">Distressed & Stained</option> <option value="Jacobean">Jacobean</option> <option value="Fumed">Fumed</option> <option value="Limed">Limed</option> </select> </label> </p> <p><br /> </p></td> </tr> <tr> <td height="40" class="formText"><span class="style15">REQUEST A BROCHURE</span></td> <td class="formText"><label> <input name="brochureyes" type="checkbox" id="brochureyes" value="send-brochure" checked="checked" /> <span class="style15">YES, PLEASE </span></label></td> </tr>
Any thoughts?
Cheers
Well, I don't see a field called "ifother", but as far as the other two, the important thing is that any "value" comes after "type" and "name".
If you want, you can reverse the "name" and "type" for "keepinformed" and see if it makes a difference.
Also, you should use "sampletype[]" since it's a field that accepts multiple values. In your email, any multiple values for a specific field will be separated by a comma.
Any fields you specify in the template must be either be required to make sure that they're filled in, or you need to define a value for TemplateMissing in the mail_options field.
That will just leave a blank for any unfilled fields. If you wanted something else in unfilled fields, you could put something like "TemplateMissing=n/a" which would put n/a for any field that's not filled in.HTML Code:<input type="hidden" name="mail_options" value="HTMLTemplate=yourtemplate.html,TemplateMissing=" />
You are putting the dollar sign in front of the field name in the template aren't you?
gingerCode:$keepinformed <br /> $sampletype[] <br /> $brochureyes <br />
Great, it works now. Thanks for all your help Ginger.
Cheers
M
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks