Jump to content

Need help in a PHP Mailer Form!!


GFXUniverse

Recommended Posts

Hi guyz.

 

I need to create a Booking System using form. same like this: https://www.theorytest.net/book-your-theory-test.php

 

Information will be sent to Email.

 

I know the form creation and sending to Email as well! But i this form is divided into pages how can i collect information that will be available to send through email at the end. (when user will complete this booking)

 

Waiting for your reply

Thanks

Link to comment
Share on other sites

Hi,

 

I suppose it depends on what you have available.

 

If you have a database back end I would validate and store the information at each stage. Then once complete you can retrieve all of the required information from the database and send your email. This method will also mean that you can easily allow the user to go back and edit their details at various stages.

 

The other method would be to have hidden fields on the next stage and when you submit your form to stage 2 (for example) you populate the hidden fields with the $_POST items from stage 1.

 

I hope that this makes sense

 

Regards

Matt

Link to comment
Share on other sites

You could use session variables to store the values along the way.

 

for example:

 

page 1 form will POST the info of the completed fields to page 2 and to store them in a session variable you do the following:

 

session_start();
$_SESSION['name'] = $_POST['name'];
//...
//...
//etc...

 

And for page 2 you do the same thing in page 3

Link to comment
Share on other sites

PHPMailer is no longer being handled, so you are not likely to get any help from the SourceForge site. I have used PHPMailer a number of times on different servers, both Windows and *nix, and i have not run into the double-mailing you've described, so I'm afraid I have no words of wisdom for you based on the information you've provided us. If you want a more up-to-date mailer solution, you might want to consider Swift Mailer.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.