The php files are mail1.php, mail3.php and so on
For safety sake I have created a dummy email address just incase it gets spammed - firstname.lastname@example.org
In keeping with many programing efforts the process is an iterative one, making small changes and then testing. It is easy to break the php handler causing it to crash and error out. If this happens then this needs to be fixed before changing the html and the form itself.
The form is the easy bit - the layout of the elements
Data from form
Sending mail with extra headers as array and data from form elements
The form above and the associated php work as well as I want them at the present time. The form is not as elegant as it could be and the php leaves the user on a non-responsive page which requires a previous page click. I do have an alert box (which is responsive) but I have not worked out how to return to page with the form on it - yet.
Actually this form seems to have broken - Example 1 below still works - and "data from form" is being debugged - AGAIN! I thought that I had the headers in an array working - I didn't - but I do now.
I need to do more on this, but in the meantime I may want to disable any access to the Apache mail() function (actually it is SendMail - the mail() is a php function).
The form above works and sends an email from my HostingUK username.
Sending mail with extra headers as array - 3 lines of hard-coded text as a message. I think that this now works! mail3.php has now been debugged I think.
The forms will be disabled until they are both "hardened" or actually required for testing or use on my site.
This may be overkill, but in the past I have seen php mailing scripts being "bombarded" with POST requests with data in fields with names that are commnly used as parameters passed to the php mail() function. These include $to:, $from:, $subject and $message - for this reason I intend to change these to $Huw, $Clunes, $Bindo and $keKe - $KeKe is an array containing reply-to, cc and bcc etc.
- Booking Form
- Using a database for possible use for a comment factility
- Recap on my work on Forms
- Form Elements
- Webforms and security - I may have to disable these forms