MyBB Community Forums

Full Version: Edit 'New Private Message at..' email
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey,

I cannot locate the area to change the email sent out when users on my forum receive a new private message. I would like to put the subject of the Private Message in the email subject.

I am usually pretty good with this stuff however I cannot find it in the Admin CP or in the server files Sad

Thanks! Big Grin

EDIT: I found the variables located in the Admin CP under Languages > messages.lang.php.. It says "New Private Message at {1}" - How can I find where "emailsubject_newpm" is used so I can insert additional variables such as PM subject or something so I can have
"New PM: {2}" where {2} is the PM Subject?

I found in ./inc/datahandlers/pm.php it references:
$emailsubject = $userlang->emailsubject_newpm;

then

$emailsubject = $lang->sprintf($emailsubject, $mybb->settings['bbname']);

I understand I need to edit the variable to say "New PM: {1}" where {1} is the subject, however, in the pm.php file im not sure how I access the Subject of the PM to insert into the email subject Sad

I tried "$emailsubject = $lang->sprintf($emailsubject, $pm['subject']]);" but this just broke it lol.. Not sure why because a few lines earlier $pm is used, so I should have access to it :/