Add More Options While Mass Mailing
#1
Star 
If you want to make additional "Personalize Messages" and to give more options while creating Mass Mailing, then this tutorial is for you. For more info: http://community.mybb.com/thread-105964.html

(2011-10-15, 10:03 PM)Jason L. Wrote: I think it would be useful if we can have custom PM functions. By this I mean in PM's we can say something like this:

Quote:Hello {username},

Hi my name is {myprofile} and I am just here to say hello.

Thanks!
{myusername}
{myemail}

Then it will output something like this:

Quote:Hello faviouz,

Hi my name is Jason L. and I am just here to say hello.

Thanks!
Jason L.
[email protected]

eh?

Lets start on the editing.

At the beginning of this tutorial, your Mass Mail page will be shown like this;
   

Open ./admin/modules/user/mass_mail.php and find;
	$replacement_fields = array(
		"{username}" => $lang->username,
		"{email}" => $lang->email_addr,
		"{bbname}" => $lang->board_name,
		"{bburl}" => $lang->board_url
	);
Note: the above code will be shown in two instances, you've to edit both instances.

And Change it into;
	$replacement_fields = array(
		"{username}" => $lang->username,
		"{email}" => $lang->email_addr,
		"{bbname}" => $lang->board_name,
		"{bburl}" => $lang->board_url,
		"{myprofile}" => $lang->my_profile,
		"{myusername}" => $lang->my_username,
		"{myemail}" => $lang->my_email
	);

Now open ./inc/languages/english/admin/user_mass_mail.lang.php and find;
$l['board_url'] = "Board URL";
and Add the following code just Beneath it;
$l['my_profile'] = "My Profile";
$l['my_username'] = "My Username";
$l['my_email'] = "My Email";

At this point your Mass Mail Page will become like this;
   

Now open ./inc/tasks/massmail.php and find;
			$replacement_fields = array(
				"{uid}" => $user['uid'],						
				"{username}" => $user['username'],
				"{email}" => $user['email'],
				"{bbname}" => $mybb->settings['bbname'],
				"{bburl}" => $mybb->settings['bburl'],
				"[".$lang->massmail_username."]" => $user['username'],
				"[".$lang->email_addr."]" => $user['email'],
				"[".$lang->board_name."]" => $mybb->settings['bbname'],
				"[".$lang->board_url."]" => $mybb->settings['bburl']
			);

and Change it into;
			$my_profile = '[url='.$mybb->settings['bburl'].'/member.php?action=profile&uid='.$mybb->user['uid'].']'.$mybb->user['username'].'[/url]';
			$replacement_fields = array(
				"{uid}" => $user['uid'],						
				"{username}" => $user['username'],
				"{email}" => $user['email'],
				"{bbname}" => $mybb->settings['bbname'],
				"{bburl}" => $mybb->settings['bburl'],
				"{myprofile}" => $my_profile,
				"{myusername}" => $mybb->user['username'],
				"{myemail}" => $mybb->user['email'],
				"[".$lang->massmail_username."]" => $user['username'],
				"[".$lang->email_addr."]" => $user['email'],
				"[".$lang->board_name."]" => $mybb->settings['bbname'],
				"[".$lang->board_url."]" => $mybb->settings['bburl']
			);

This'll personalize both your Mass Emails and Mass Private Messages.

Now when you Create a New Mass Mail, it'll look something like this;
   

And when you send a Private Message for example, it'll show to the end user like this;
   

Thanks for reading.
Reply
#2
I didnt really mean it like this...I meant when you send a PM and type multiple recipients.
Reply
#3
This user has been denied support. This user has been denied support.
I guess he meant through normal PMs, like any user can use, but not like sending from ACP.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)