1
dharley
Email Notification
  • 2006/3/28 2:55

  • dharley

  • Just popping in

  • Posts: 8

  • Since: 2005/12/16


How can I alter the email that the Admin receives when a new user joins a site. I have found the template that is emailed. adminactivate.tpl.

And in the register.php file in the modules\profile folder.

How do I add the fields that the new user fills out on the registration form? I would like the information on the email to review before going to the site to activate the user..

Thanks for your assistance...

David Harley

2
Guido83
Re: Email Notification
  • 2006/8/3 14:40

  • Guido83

  • Just popping in

  • Posts: 60

  • Since: 2003/12/7


I would like to know the same. Anyone?

3
wtravel
Re: Email Notification

In the file register.php on line 255 (XOOPS 2.0.14) you will find:

$xoopsMailer->setBody(sprintf(_US_HASJUSTREG, $uname));

The sprintf() function in this case, places the variable $uname in the constant _US_HASJUSTREG at placeholder %s. You can add more than one placeholders like that.

For example:
$xoopsMailer->setBody(sprintf(_US_HASJUSTREG, $var1, $var2, $var3, $var4));

Make sure that the constant _US_HASJUSTREG has 4 placeholders in that case.

To get the data submitted by the user use the object function $newuser->getvar();

Example of use:
$newuser_name $newuser->getVar('uid');
$newuser_sitename $newuser->getVar('url');
$newuser_yim $newuser->getVar('user_yim');
$newuser_email $newuser->getVar('email');
$xoopsMailer->setBody(sprintf(_US_HASJUSTREG$uname$newuser_sitename$newuser_yim$newuser_email));


Don't forget to adjust the template as well if necessary.

Hope this helps

Login

Who's Online

294 user(s) are online (235 user(s) are browsing Support Forums)


Members: 0


Guests: 294


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits