+
+
+/*
+ * send registration confirmation.
+ * It's here as a function because the mail is sent
+ * from different parts
+ */
+function send_register_open_eml($email, $sitename, $siteurl, $username, $password){
+ $preamble = deindent(t('
+ Dear %1$s,
+ Thank you for registering at %2$s. Your account has been created.
+ '));
+ $body = deindent(t('
+ The login details are as follows:
+ Site Location: %3$s
+ Login Name: %1$s
+ Password: %5$s
+
+ You may change your password from your account "Settings" page after logging
+ in.
+
+ Please take a few moments to review the other account settings on that page.
+
+ You may also wish to add some basic information to your default profile
+ (on the "Profiles" page) so that other people can easily find you.
+
+ We recommend setting your full name, adding a profile photo,
+ adding some profile "keywords" (very useful in making new friends) - and
+ perhaps what country you live in; if you do not wish to be more specific
+ than that.
+
+ We fully respect your right to privacy, and none of these items are necessary.
+ If you are new and do not know anybody here, they may help
+ you to make some new and interesting friends.
+
+
+ Thank you and welcome to %2$s.'));
+
+ $preamble = sprintf($preamble, $username, $sitename);
+ $body = sprintf($body, $email, $sitename, $siteurl, $username, $password);
+
+ return notification(array(
+ 'type' => "SYSTEM_EMAIL",
+ 'to_email' => $email,
+ 'subject'=> sprintf( t('Registration details for %s'), $sitename),
+ 'preamble'=> $preamble,
+ 'body' => $body));
+}