Can Universal Email set the To address..
I have a client that wants to set one or multiple To: email address via check boxes on the contact form Is that possible in Universal Email? Thanks
I have a client that wants to set one or multiple To: email address via check boxes on the contact form Is that possible in Universal Email? Thanks
yes, just make sure to use the same name for each of the checkboxes, and end the name with "[]". for example:
<label>
<input type="checkbox" name="toEmail[]" value="support@myCompany.com" id="toEmail_0" />
support</label>
<br />
<label>
<input type="checkbox" name="toEmail[]" value="sales@myCompany.com" id="toEmail_1" />
sales</label>
<br />
<label>
<input type="checkbox" name="toEmail[]" value="info@myCompany.com" id="toEmail_2" />
info</label>
this will create an array of each of select checkboxes.
then In universal email, use the following code for the two address:
<?php echo((isset($_POST["toEmail"]))?implode(", ",$_POST["toEmail"]):"") ?>
this use the php implode function to convert the array to a comma separated list
Hi Jason
I have this working perfectly on one site, but can't replicate it on the current - the only difference, I think, between the two is that the current is a Windows server, running php, wheras the other is Linux, though this may be irrelevant!
<input type="checkbox" name="toEmail[]" value="<?php echo $row_rsMembers['MemEmail']; ?>" id="toEmail_<?php echo $row_rsMembers['RotID']; ?>" />
in the form
and
<?php echo((isset($_POST["toEmail"]))?implode(", ",$_POST["toEmail"]):"") ?>
in the UE.
Might there be a missing function in php on the windows server that's preventing things? Other email - e.g. multiples sent to recordset, individual eamails - using UE work fine.
Any suggestions?
Thanks
Chris
send a copy of your page please and a copy of the webassist/email folder so i can examine the code in context.
Thanks Jason.
Files attached
Cheers
Chris
i must be missing something, the page you have sent, forgotten_password.php, does not include a checkbox on it?
I dont believe you have sent the correct file?
Hi Jason
Sorry about that - the password file relates to another open thread (showthread.php?t=24636)
Attached file has the checkboxes on the 'email members' tab. You have the webassist/email folder.
Many thanks
Chris
I have created a support ticket so we can look into this issue further.
To view and edit your support ticket, please log into your support history:
supporthistory.php
If anyone else is experiencing this same issue, please append to this thread.
Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.
These out-of-the-box solutions provide you proven, tested applications that can be up and running now. Build a store, a gallery, or a web-based email solution.