rejected email template not working

Hi,

For some reason, all my email notification work except the one for rejected profile. Would someone have an idea?

Thank

Quote · 21 Aug 2009

No one knows why the rejected validation status email isn't sent?

Thank

Quote · 23 Aug 2009

So far, here are my findings:

BxDolProfilesController.php doesn't have a function to send out email when profile status is changed to "Rejected".

I added it:

====

function sendRejectMail( $iMemID ) {
$iMemID = (int)$iMemID;
$aMember  = $this -> getProfileInfo( $iMemID );
if( !$aMember )
return false;

$sEmail   = $aMember['Email'];
$sSubject = getParam('t_Rejection_subject');
$sMessage = getParam('t_Rejection');

return sendMail( $sEmail, $sSubject, $sMessage, $iMemID );
}

====

and added the red text bellow:

====

//collect status text
if( $bSendMails and !$aMainMember ) { //send mail only to main member, not to couple
if( getParam('autoApproval_ifNoConfEmail') == 'on' ) {
if ( getParam('autoApproval_ifJoin') == 'on' ) {
$sStatusText = 'Active';
$this -> sendActivationMail( $iNewID );
} else {
$sStatusText = 'Approval';
$this -> sendApprovalMail( $iNewID );
}
} else {
if( $this -> sendConfMail( $iNewID ) )
$sStatusText = 'Unconfirmed';
else
$sStatusText = 'NotSent';
}
if( $sStatusText = 'Rejected' )  {
$this -> sendRejectMail( $iNewID );
}

} else
$sStatusText = 'OK';

====

But it still doesn't send out the email for rejected profiles.

I'm surprised nobody brought that problem before, as the function doesn't exist but the rejection email is present in the "Email Templates"... or it's calling another function sowhere else I ignore.

Quote · 23 Aug 2009

Ok... I realized "Rejected" and "active" status email aren't sent but "email address confirmation" is, as well as cupid emails.

Some help is welcome...

Quote · 24 Aug 2009

Resolved.

Activation email is sent ONLY if the account is activated from the Admin Panel (admin/profiles.php), not from the "Admin edit profile page" (pedit.php) even if you can change status there.

But regarding the Reject email, I had to add the function as described above and create a "Reject" button in the Admin Panel, next to the "Activate" one.

In admin/profiles.php:

Following this code:

====

case 'Activate':
$iProfileID = (int)$val;
if ($iProfileID) {
db_res( "UPDATE `Profiles` SET `Status` = 'Active' WHERE `ID` = '{$iProfileID}'" );
createUserDataFile($iProfileID);
reparseObjTags( 'profile', $iProfileID );

$iPossibleCoupleID = (int)db_value( "SELECT `ID` FROM `Profiles` WHERE `Couple` = '{$iProfileID}'" );
if ($iPossibleCoupleID) {
db_res( "UPDATE `Profiles` SET `Status` = 'Active' WHERE `ID` = '{$iPossibleCoupleID}'" );
createUserDataFile($iPossibleCoupleID);
reparseObjTags( 'profile', $iPossibleCoupleID );
}
}
$oPC -> sendActivationMail( (int)$val );
break;

====

add:

====

case 'Rejected':
$iProfileID = (int)$val;
if ($iProfileID) {
db_res( "UPDATE `Profiles` SET `Status` = 'Rejected' WHERE `ID` = '{$iProfileID}'" );
createUserDataFile($iProfileID);
reparseObjTags( 'profile', $iProfileID );

$iPossibleCoupleID = (int)db_value( "SELECT `ID` FROM `Profiles` WHERE `Couple` = '{$iProfileID}'" );
if ($iPossibleCoupleID) {
db_res( "UPDATE `Profiles` SET `Status` = 'Rejected' WHERE `ID` = '{$iPossibleCoupleID}'" );
createUserDataFile($iPossibleCoupleID);
reparseObjTags( 'profile', $iPossibleCoupleID );
}
}
$oPC -> sendRejectMail( (int)$val );
break;

====

and add with the other buttons code ~line 550:

====

<td width="90" align="center"><input class=text type=submit name="prf_form_submit" value="Rejected" /></td>

====

Now profile rejected from the Admin Panel will receive the "Reject" email from the email templates.

Quote · 24 Aug 2009

Nadja!

I must admit that your determination to solve this problem is plausible!

The peculiar silence from the community is scary and shameful.

I am trying to deal with the very same problem in D7.0.4...

Hopefully will get there some day.

All the best!

Eugene

Quote · 15 Jan 2011

... same prob, too. Can't believe there is a template but no function!?

Quote · 19 Feb 2011

 

Nadja!

I must admit that your determination to solve this problem is plausible!

The peculiar silence from the community is scary and shameful.

I am trying to deal with the very same problem in D7.0.4...

Hopefully will get there some day.

All the best!

Eugene

 I love how you come in here, offer nothing contributory except to bust on the community for not having the answer for him and post that we all should of jumped up and down to fix this problem.  As far as a solution to the problem, he gave it to you right above, just take a moment to look.  The community is here to help with the things that we know the answer to and if we have a moment to develop something we don't know the answer to then we can.  In this case Nadja's dedication to resolving this issue is highly admirable, your dedication to ripping on the community while providing no solutions to problems is also highly commendable in it's own right.

Quote · 22 Feb 2011

hi,  

It might be better if it's a default 'no' option to send an email to a Rejected member.  Currently I'm using "Rejected" profiles for people who signed up but have no good reason to do so (e.g. they live half way around the world from my local community website).  In this case I prefer to not send them anything... just keep their email's associated signup as Rejected.  Of course I do other things to block such people but some find a way to my site despite such attempts.  

Thank you

http://pkforum.dolphinhelp.com
Quote · 18 Jan 2012
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.