Update - Apr 13 03:35 PM: I fixed another small bug that occured when you used email verification.
------------------------------------------------------------------------
This hack was requested by RobAC. It sends a welcome email to a new registrant at your board automatically. You can change the email wording to whatever you like, and turn the feature itself on or off in your Admin CP. If you require your new users to verify their email, it waits until that is done to send the welcome email. Otherwise, it sends it right away.
No demo, for obvious reasons. However, you can register at the vGeekIsland Board (link in my sig) to see it working. Or you could register there anyway, to help us build up our small community.
For version: version 2, beta 5
Files needed: none
Files to edit: register.php
Templates to create: email_welcome, emailsubject_welcome
Instructions
1] Open register.php in an ASCII editor (you know at this point why you can't open it in a WYSIWYG editor; if not, read any of the hack threads in my sig).
2] Around line 414, find
Right below this, add
Then, around line 489, find
Add right below it
3] Save and upload register.php. Then upload welcomemysql.php to your forums /admin directory. Go to http://yoururl.com/forums/admin/welcomemysql.php in a browser. If it is successful, it will display a link to you Admin CP.
4] Follow the link, and then create two new templates. First, one called email_welcome, filled with this:
Then, create another one called emailsubject_welcome and fill it with this:
That's it. You can check out the new option under "Change Options" in the Admin CP.
Instructions are also in the zip file - welcome.txt.
Please do not PM me or contact me via AIM or ICQ about this hack. Post your message here - I will see it and try to help you.
Enjoy!
Edit: Almost forgot this. In the email_welcome template, you have these variables available to you:
$username - inserts the username of the recipient
$bbtitle - inserts the title of your BB
$u - inserts the userid of the recipient
$email - inserts the email address of the recipient
$webmasteremail - inserts the webmaster's email address
------------------------------------------------------------------------
This hack was requested by RobAC. It sends a welcome email to a new registrant at your board automatically. You can change the email wording to whatever you like, and turn the feature itself on or off in your Admin CP. If you require your new users to verify their email, it waits until that is done to send the welcome email. Otherwise, it sends it right away.
No demo, for obvious reasons. However, you can register at the vGeekIsland Board (link in my sig) to see it working. Or you could register there anyway, to help us build up our small community.
For version: version 2, beta 5
Files needed: none
Files to edit: register.php
Templates to create: email_welcome, emailsubject_welcome
Instructions
1] Open register.php in an ASCII editor (you know at this point why you can't open it in a WYSIWYG editor; if not, read any of the hack threads in my sig).
2] Around line 414, find
Code:
eval("\$subject = \"".gettemplate("emailsubject_activateaccount",1,0)."\";"); mail($email,$subject,$message,"From: \"$bbtitle Mailer\" <$webmasteremail>"); }
Code:
// send a welcome email using email_welcome and emailsubject_welcome templates, but don't // send it now if they need to activate their account if (!$verifyemail && $welcomeuser) { eval("\$message = \"".gettemplate("email_welcome",1,0)."\";"); eval("\$subject = \"".gettemplate("emailsubject_welcome",1,0)."\";"); mail($newuseremail,$subject,$message,"From: \"$bbtitle Mailer\" <$webmasteremail>"); } // end send mail
Code:
eval("standarderror(\"".gettemplate("error_moderateuser")."\");"); } else {
Code:
// send a welcome email using email_welcome and emailsubject_welcome templates but only if it's on if ($welcomeuser) { $email = $userinfo[email]; $username = $userinfo[username]; eval("\$message = \"".gettemplate("email_welcome",1,0)."\";"); eval("\$subject = \"".gettemplate("emailsubject_welcome",1,0)."\";"); mail ($email,$subject,$message,"From: \"$bbtitle Mailer\" <$webmasteremail>"); } // end send mail
4] Follow the link, and then create two new templates. First, one called email_welcome, filled with this:
Code:
Dear $username, On behalf of the $bbtitle team, I would like to welcome you to our forums. I hope you enjoy your stay and would like you to know that if you ever have any problems, please do not hesitate to contact me or one of the other team members. I have listed our emails below for future reference. Once again, thanks for joining us! I hope you have a long and enjoyable stay with us. Sincerely, the $bbtitle team
Code:
Welcome to $bbtitle!
Instructions are also in the zip file - welcome.txt.
Please do not PM me or contact me via AIM or ICQ about this hack. Post your message here - I will see it and try to help you.
Enjoy!
Edit: Almost forgot this. In the email_welcome template, you have these variables available to you:
$username - inserts the username of the recipient
$bbtitle - inserts the title of your BB
$u - inserts the userid of the recipient
$email - inserts the email address of the recipient
$webmasteremail - inserts the webmaster's email address
Comment