DavidAM Posted March 20, 2010 Share Posted March 20, 2010 If form.php is the original contact form, then you can put all of the code in this one file and do away with the second file contact.php. You will note in the example code I posted that the action attribute of the form is blank, this causes the form to post to the same file that it is in (in this case form.php). You can explicitly put form.php there but if you later change the name of the file you will have to change it in the action as well (of course you will be changing it on other pages that link to it, so that is no big deal). So, basically, the code I posted becomes form.php and you delete contact.php (well, save it off somewhere incase you want to refer to it later). Note, that I did not include any of your processing that builds up the mail parameters in the example, you will have to cut and paste that as needed. I did not test that code, so it may have some issues. If you run into any problems, continue to post the problems, code and error messages. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.