I have created a rather extensive submission form. The user selects the recipient from a drop down menu.
Once submitted I want a copy of the form emailed to the user. How can I accomplish this?
Once submitted I want a copy of the form emailed to the user. How can I accomplish this?
Hi bigsecz,
Please see this FAQ - it is for an early version of CFv4 but the same method is used in Cfv5.
Bob
Please see this FAQ - it is for an early version of CFv4 but the same method is used in Cfv5.
Bob
Hi Bob
Can I also use this feature if I want to send a copy to a logged in user? I use this code to get the user data:
Can I send a copy to the mail to 'username'?
Thanks!
Can I also use this feature if I want to send a copy to a logged in user? I use this code to get the user data:
<?php
$user =& JFactory::getUser();
$profile = JUserHelper::getProfile($user->id);
?>
<input type='text' name='name' id='name' value='<?php echo $user->name; ?>'
<input type='text' name='username' id='username' value='<?php echo $user->username; ?>'
Can I send a copy to the mail to 'username'?
Thanks!
Hi bigsecz,,
That should work OK - but you don't need the $profile line as you aren't using those values anywhere.
Bob
That should work OK - but you don't need the $profile line as you aren't using those values anywhere.
Bob
Hi Bob
Thanks for your answer. So just the snippet:
<?php echo $user->username; ?>
Can you tell me where I can paste this code?
Thanks for your answer. So just the snippet:
<?php echo $user->username; ?>
Can you tell me where I can paste this code?
Hi Bob
I've tried different possibilities to send a copy of the mail to the logged in user. I have followed the video tutorial, draged a second e-mail box in the 'on submit action' and used the 'dynamic to' field and entered:
username
and
<?php echo $user->username; ?>
but both options don't work. What am I doing wrong?
Thanks!
I've tried different possibilities to send a copy of the mail to the logged in user. I have followed the video tutorial, draged a second e-mail box in the 'on submit action' and used the 'dynamic to' field and entered:
username
and
<?php echo $user->username; ?>
but both options don't work. What am I doing wrong?
Thanks!
Hi bigsecz,
All of the information you need is in the FAQ
In the On Submit event add a Custom Code action, drag it up before the Email action and add this code
Bob
All of the information you need is in the FAQ
In the On Submit event add a Custom Code action, drag it up before the Email action and add this code
<?php
$user =& JFactory::getUser();
$form->data['user_email'] = $user->email;
?>
Then put user_email in the Dynamic To box of the Email action
Bob
Hi Bob
Thanks, that seems to work. However... somehow the module doesn't send e-mails to hotmail or gmail. I have checked all your sugestions on http://www.chronoengine.com/faqs/52-cfv4/cfv4-emails/2623-why-arent-my-emails-being-delivered.html
but without result. Debugger mentions that mails have been sent succesfully.
Thanks, that seems to work. However... somehow the module doesn't send e-mails to hotmail or gmail. I have checked all your sugestions on http://www.chronoengine.com/faqs/52-cfv4/cfv4-emails/2623-why-arent-my-emails-being-delivered.html
but without result. Debugger mentions that mails have been sent succesfully.
Hi Rutger1973,
Please drag a Debugger action into the On Submit event, then submit the form and post the debug - including the 'dummy emails' results here.
Note: if you are using the Easy Wizard you can turn on Debug on the Others tab in CFv4 or the Setup tab in CFv5.
Bob
Please drag a Debugger action into the On Submit event, then submit the form and post the debug - including the 'dummy emails' results here.
Note: if you are using the Easy Wizard you can turn on Debug on the Others tab in CFv4 or the Setup tab in CFv5.
Bob
Hi Bob
Seems that Gmail is working (mail was in spam folder), hotmail is still not working. Als made a small testform with just 1 textbox, same results. Debugger info is rather large so will send it by PM.
Thanks
Seems that Gmail is working (mail was in spam folder), hotmail is still not working. Als made a small testform with just 1 textbox, same results. Debugger info is rather large so will send it by PM.
Thanks
Hi Rutger1973,
ChronoForms will be sending the email in both cases. It looks as though Hotmail is marking the emails as possible spam and dropping them :-(
It looks to me as if the From Email may not match the site domain - that can cause email problems.
It could also be the long list of wines that cause the problem. I'd be inclined to add some PHP to the output to remove all the 'empty' options from the email.
Bob
ChronoForms will be sending the email in both cases. It looks as though Hotmail is marking the emails as possible spam and dropping them :-(
It looks to me as if the From Email may not match the site domain - that can cause email problems.
It could also be the long list of wines that cause the problem. I'd be inclined to add some PHP to the output to remove all the 'empty' options from the email.
Bob
Hi Bob
I would be very happy to remove all the 'empty' options but I don't know how. Is this a special feature I can add to the form by the editor? I don't know how to write PHP so if it requires customized PHP code, I have no clue how to add this.
Thanks!
I would be very happy to remove all the 'empty' options but I don't know how. Is this a special feature I can add to the form by the editor? I don't know how to write PHP so if it requires customized PHP code, I have no clue how to add this.
Thanks!
This topic is locked and no more replies can be posted.