This forum is no longer open and is for reading/searching only.
Please use our new MachForm Community Forum instead.
MachForm Community Forums » MachForm 2
Multiple email addresses notification
Started 15 years ago by rafavalles | 14 posts |
-
I cannot use the multiple email option, because on the second box (users) option is displaying me a dropbox with the option email anbd then a blank.
I mean this function
Email integration
For every form submission, you will receive instant email notification containing complete form submission data. Multiple email addresses are supported. This allows you to respond quickly to your users.
Posted 15 years ago # -
Hmm.. I'm not sure I understand this correctly.
Do you need your users to be able entering multiple email addresses into the form and then send autoresponder to those emails?
The function you are referring, meant for the "You" side of the email setting. So you can send the result of your form submission to multiple email addresses.
While the autoresponder can only be sent to one user (which is by design, since the person who fill you form is just one person).
Am I missing something?
MachForm Founder
Posted 15 years ago # -
No I get a little bit more the Your Users side
But i dont know how to send notifications of formdelivery to multiple users, is it possible ??
I mean to get the form notification (my mail and some other administrator), so we can respond faster...
Posted 15 years ago # -
Yes, that's possible. Simply put multiple email addreses on the "You" side. Separate them by comma.
Example: user1@example.com, user2@example.com, user3@example.com
That would send form notification to the above addresses.
MachForm Founder
Posted 15 years ago # -
finally, thanks!!
Posted 15 years ago # -
Is there a limmit to the number of email addresses seperated by comma? Seems to only allow about 7-8 emails here and I need to send to more then 50.
It would be better to have a flat file to add email addresses to and then I could ad as many as i needed.
Is there a way to replace your code where it get multiple email addresses from "Your Email Address" line which is limited to 8-10 emails with code that opens a CSV flat file of emails listed 1 after another?
Replacing the "mail" function in example code with your send mail method you already use.
Sample code below to open a CSV file of names to send to:
$handle = @fopen("emails.csv", "r");
if ($handle) {
while (!feof($handle)) {
$email = fgets($handle);
mail($email, $subject, $message, $headers);
}
fclose($handle);
}
}Posted 15 years ago # -
At this moment the "Your Email Address" is limited to 255 characters.
If you need more, you need to open your machform database (using PhpMyAdmin) and go to your "ap_forms" table.
Change the field type of "form_email" column into MEDIUMTEXT.
That would allow your machform to accept hundreds or thousands of email address.MachForm Founder
Posted 15 years ago # -
Can you use something like {element_25} in place of an actual email address if you do not know what the email address will be until after the form has been filled out?
Posted 15 years ago # -
Yes
MachForm Founder
Posted 15 years ago # -
Thanks, this works and now I am writing code to use an external CSV file of email addresses or a database list.
Posted 15 years ago # -
Thanks Yuniar.
Posted 15 years ago # -
I tried to place the {element_25} on the You side and got an incorrect email format error.
Posted 15 years ago # -
Sorry, my fault. I forgot that you can't do that by default.
For security reason, we shouldn't let the user enter their own destination email address.Otherwise, your user can use your form to send the form to any person. Thus spamming them.
However, if you really need it and aware of the risk above, edit your email_settings.php, search around line 106:
if(empty($result)){ $esl_valid_email = false; break; }
change it to become:
if(empty($result)){ $esl_valid_email = true; break; }
MachForm Founder
Posted 15 years ago # -
I suggest using this method instead:
http://www.appnitro.com/forums/topic/email-from-a-drop-downlist?replies=9It's secure that way.
MachForm Founder
Posted 15 years ago #
Reply
You must log in to post.