What do I have to change in the code below to stop Dolphin from sending out the "your membership has changed" email (t_MemChanged)
Can I simply comment out this line?: (memberships_levels.inc.php)
sendMail( $aProfileInfo['Email'], $aTemplate['Subject'], $aTemplate['Body'], $iMemberId, $aTemplateVars);
/**
* set lifetime membership if 0 days is used.
*/
$iDateExpires = $iDays != 0 ? (int)$iDateStarts + $iDays * $SECONDS_IN_DAY : 'NULL';
db_res("INSERT `sys_acl_levels_members` (`IDMember`, `IDLevel`, `DateStarts`, `DateExpires`, `TransactionID`) VALUES ('" . $iMemberId . "', '" . $iMembershipId . "', FROM_UNIXTIME(" . $iDateStarts . "), FROM_UNIXTIME(" . $iDateExpires . "), '" . $sTransactionId . "')");
if(db_affected_rows() <= 0)
return false;
//Set Membership Alert
bx_import('BxDolAlerts');
$oZ = new BxDolAlerts('profile', 'set_membership', '', $iMemberId, array('mlevel'=> $iMembershipId, 'days' => $iDays, 'starts_now' => $bStartsNow, 'txn_id' => $sTransactionId));
$oZ->alert();
$oEmailTemplate = new BxDolEmailTemplates();
$aTemplate = $oEmailTemplate->getTemplate('t_MemChanged', $iMemberId);
$aMembershipInfo = getMembershipInfo($iMembershipId);
$aTemplateVars = array(
'MembershipLevel' => $aMembershipInfo['Name']
);
sendMail( $aProfileInfo['Email'], $aTemplate['Subject'], $aTemplate['Body'], $iMemberId, $aTemplateVars);
return true;