EMAIL_ADDRESS_REGISTER_NOTIFICATION syntax?

Permalink
Hello,

With the latest patch notifications when new users register looks like it's now built into the C5 core, but I can't find any documentation on what parameters they take (if any), I'm also assuming that this is defined inside site.php. Is there documentation on this anywhere?

"You can define EMAIL_ADDRESS_REGISTER_NOTIFICATION and EMAIL_ADDRESS_REGISTER_NOTIFICATION_FROM to get notifications when new users register through your site."


Thanks,

Ben

 
andrew replied on at Permalink Best Answer Reply
andrew
Yes, it'd be added to site.php

define('EMAIL_ADDRESS_REGISTER_NOTIFICATION', 'notify@mysite.com');
define('EMAIL_ADDRESS_REGISTER_NOTIFICATION_FROM', 'notify-from@mysite.com');


Then, when new users register, notify@mysite.com will be emailed with an update, and it will come from the address notify-from@mysite.com. (Note, the second parameter is optional.)
sschildbach replied on at Permalink Reply
sschildbach
Andrew,

Do I need to replace notify@mysite.com with the administrator's email address? I tried putting your code in site.php and I'm not getting any registration confirmation email. On my localhost testing site, I don't get any email and on my remote site I get php errors. What I'm I missing? Is having define('PERMISSIONS_MODEL', 'advanced'); before it screwing things up?
BAC replied on at Permalink Reply
Added these definitions to my config/site.php file and all seems to work fine. I get an email notification and the user, who needs to be manually approved, gets created. Problem is once the user registers they get the following errors. (we are using concrete version 5.4.2.1) Any ideas?
--------------------------------------
Warning: Invalid argument supplied for foreach() in D:\vhosts\mysite.com\httpdocs\concrete\mail\user_register_approval_required.php on line 14

Warning: Cannot modify header information - headers already sent by (output started at D:\vhosts\mysite.com\httpdocs\concrete\mail\user_register_approval_required.php:14) in D:\vhosts\mysite.com\httpdocs\concrete\models\user.php on line 69

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at D:\vhosts\mysite.com\httpdocs\concrete\mail\user_register_approval_required.php:14) in D:\vhosts\mysite.com\httpdocs\concrete\models\user.php on line 71

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at D:\vhosts\mysite.com\httpdocs\concrete\mail\user_register_approval_required.php:14) in D:\vhosts\mysite.com\httpdocs\concrete\models\user.php on line 71

Warning: Cannot modify header information - headers already sent by (output started at D:\vhosts\mysite.com\httpdocs\concrete\mail\user_register_approval_required.php:14) in D:\vhosts\mysite.com\httpdocs\concrete\libraries\controller.php on line 350