Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 255
  • Last Modified:

Php E-mail Based Survey

Hi,
  I am trying to make a survey to send out to customers. I already have a Web-Based one, however, I would like to send an e-mail containing the questions on the survey that will get entered into my database. I believe I have to create and attach an html form that will then connect to the database once the survey is submitted. If anyone has any better ideas could you please let me know.

Thanks,

MSP
0
Zambian4eva
Asked:
Zambian4eva
1 Solution
 
lozlozCommented:
you don't need to attach an html form unless the user can only accept plain text e-mails. you can actually write out your email using html tags, have the form action pointed at a processing script which you have stored on your server. so you'd have something like:

$message ="<form method=\"POST\" action=\"process-survey.php\">
<input type=\"radio\" name=\"quality\" value=\"1\" selected>good or <input type=\"radio\" name=\"quality\" value=\"0\">bad?
<input type=\"submit\" name=\"submit\" value=\"Send survey\">
</form>";

any questions, ask away

loz
0
 
dstarkCommented:
make sure you include a URL in the action from lozloz's script.. otherwise, it's gonna cause some issues ;)

ie: action=\"http://www.yourwebsite.com/process-survey.php\"
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now