View Full Version : Capture Data and Send Email
eaefaw380137
07-09-2009, 12:49 PM
I am using Contact Form Solution Pack and Data Assist and need to collect the data captured in the contact form in MySQL and also send the results via email. I can get both to work separately, but can't get them both to work together.
I tried adding the Insert Record server behavior from Data Assist in the action tag of the contact form, as instructed in the thread below, but I can't seem to get both to work together. Any help is appreciated.
http://www.webassist.com/forums/showthread.php?t=1798&highlight=contact+form+data
Ray Borduin
07-09-2009, 01:03 PM
Just don't set a redirect in the first one and it should let the other one process as well.
eaefaw380137
07-09-2009, 01:13 PM
Ray - thanks for the response...I am happy you have replied since you always seem to provide great support and problem solving. I have learned a lot from your responses...
With regards to your response, I have the contact form redirect to the thankyou.php page supplied via the contact form solution pack. Is that the redirect you are suggesting I remove, or the snippet of code below created by DataAssist?
$WA_redirectURL = "CONTACT_Results.php";
Thanks for your support!
Ray Borduin
07-09-2009, 02:57 PM
The email and the redirect should both appear in the server behaviors window.
Whichever appears first should not have redirect settings. If you open the interface just make sure the go to page field is blank.
eaefaw380137
07-09-2009, 06:51 PM
Ray - thanks for your patience, as I work through this. I am not sure if you are referencing the contact form page (contactus.php) created by Contact Form Solution or the Insert page (CONTACT_insert.php) created by DataAssist when you say that I have to remove the redirect from either the email or redirect in the server behaviors, depending on which came first.
Here is what i have in my server behaviors for each page and not sure where the change needs to be made. If I need to provide code samples please let me know.
Contactus.php | Server Behaviors:
WA Server Validations
Universal Mail 1 (mail)
Dynamic Text Field (Contact_Name)
Dynamic Text Field (Email_Address)
Dynamic Text Field (Comments)
Validation ShowIf (contact.php)
Validation ShowIf (contact.php)
Validation ShowIf (contact.php)
CONTACT_Insert.php | Server Behaviors
Insert Record (CONTACT)
Neither page seems to reference what you mentioned in your last post as the fix. If the answer lies in one of the above server behaviors and I am just missing it, I apologize.
Ray Borduin
07-10-2009, 07:38 AM
You should be applying the insert record server behavior on the Concatus.php page directly and not using the wizard.
eaefaw380137
07-10-2009, 07:52 AM
YES!! That was it! Thank you so much! I purchased DataAssist and the Contact Form solution pack because the Webassist sales team said I could use both to achieve this which is why I was using the wizard....I only needed the Contact Form Solution Pack and your expertise. Oh well... as long as it works, I am sure I will be able to put DataAssist extension to good use.
Thanks again!
vBulletin® v3.8.1, Copyright ©2000-2012, Jelsoft Enterprises Ltd.