Adding information on confirmation email Adding information on confirmation email
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Adding information on confirmation email

Started by icsolution, July 11, 2005, 04:26:45 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

icsolution

Hello,

I'm installing CPG on a client's site and he has requested some small modifications.
First one was to change fields "location" and "interests" from registration form to "first name" and "last name/company name" and make them required fields - I have done that successfully.

He asked to have the registration confirmation email sent to him first (I changed to be sent to gallery_admin_email successfully) so he could review the info and approve or not the request to register on the gallery, and after he would send a confirmation email to the registrant himself. But he would like to receive all information from the register form in this email - username, password, email, first name, last name and the non required information if added - and not only username and password as it is set to be.

I have added the following (register.php starting on line 223):

if ($CONFIG['reg_requires_valid_email']) {
       $act_link = "http://" . $HTTP_SERVER_VARS['HTTP_HOST'] . $PHP_SELF . '?activate=' . $act_key;
       $template_vars = array('{SITE_NAME}' => $CONFIG['gallery_name'],
   '{REGDATE}' => $user_regdate,
               '{USER_NAME}' => $user_name,
   '{FIRST_NAME}' => $first_name,
   '{LAST_NAME_COMPANY_NAME}' => $last_name_company_name,
               '{PASSWORD}' => $password,
   '{EMAIL}' => $email,
               '{ACT_LINK}' => $act_link

But the email is sent only with username and password.
I have searched other files but I didn't find anything related to the confirmation email.
I'd like you to help me on adding these fields on the email or to help me on generating a second email with this information to be sent to the gallery admin email.

Thanks a lot!

Nibbler

You'll need to add the {PLACEHOLDERS} you have added there into the email text, which is in the language files.