Match, Cupid Mail Opt Out in Dolphin 7

Ok this is an easy way to give users the option to opt out of receiving Match Notifications (Cupid Mail)

The Match System will still work for them but they will be able to Opt Out of receiving the Match Notifications.

Step 1. Create a new block in Profile Fields

Goto

Admin Panel - Builders - Profile Fields - Edit Profile, select Owner

From Inactive Blocks drag up a NEW BLOCK and rRename to "Mail Settings"

Then from Inactive Items drag up a NEW ITEM and place under Mail Settings Block

Click on the NEW ITEM to open Edit Box, then in System Name type MatchAlertMails and in Caption type Receive Match Alert Mails and in Type choose selector

Then click on the Advanced tab and set Selector control to Radio buttons then in Possible values type Yes and on the next line type No (note: must be one word/value per line) then in Default value type Yes

Step 2. Edit /inc/match.inc.php (Backup this file first)

This will tell dolphin only to send Match Notifications only to members that have not opted out.

Find: around line 67

$aProfiles = $oDb->getColumn("SELECT `ID` FROM `Profiles` WHERE `Status` = 'Active' AND `ID` != $iProfileId $sCondSort");

And replace with:

$aProfiles = $oDb->getColumn("SELECT `ID` FROM `Profiles` WHERE `Status` = 'Active' AND `MatchAlertMails` = 'Yes' AND `ID` != $iProfileId $sCondSort");

Step 3. Setting defaults in Database to MatchAlerts column in Profiles table (Backup of Database recommended first)

Run this command in phpMyAdmin

UPDATE `Profiles` SET `MatchAlertMails`='Yes' WHERE `MatchAlertMails`=''

And that's it

Now that was so easy. Why its not a default feature i would never know!

Dave....

Quote · 21 Apr 2010

wow I have been asking for help for this for a year......Thank you I needed this now more than ever.

Ok this is an easy way to give users the option to opt out of receiving Match Notifications (Cupid Mail)

The Match System will still work for them but they will be able to Opt Out of receiving the Match Notifications.

Step 1. Create a new block in Profile Fields

Goto

Admin Panel - Builders - Profile Fields - Edit Profile, select Owner

From Inactive Blocks drag up a NEW BLOCK and rRename to "Mail Settings"

Then from Inactive Items drag up a NEW ITEM and place under Mail Settings Block

Click on the NEW ITEM to open Edit Box, then in System Name type MatchAlertMails and in Caption type Receive Match Alert Mails and in Type choose selector

Then click on the Advanced tab and set Selector control to Radio buttons then in Possible values type Yes and on the next line type No (note: must be one word/value per line) then in Default value type Yes

Step 2. Edit /inc/match.inc.php (Backup this file first)

This will tell dolphin only to send Match Notifications only to members that have not opted out.

Find: around line 67

$aProfiles = $oDb->getColumn("SELECT `ID` FROM `Profiles` WHERE `Status` = 'Active' AND `ID` != $iProfileId $sCondSort");

And replace with:

$aProfiles = $oDb->getColumn("SELECT `ID` FROM `Profiles` WHERE `Status` = 'Active' AND `MatchAlertMails` = 'Yes' AND `ID` != $iProfileId $sCondSort");

Step 3. Setting defaults in Database to MatchAlerts column in Profiles table (Backup of Database recommended first)

Run this command in phpMyAdmin

UPDATE `Profiles` SET `MatchAlertMails`='Yes' WHERE `MatchAlertMails`=''

And that's it

Now that was so easy. Why its not a default feature i would never know!

Dave....

 

 

Jennifer Bogan .. Acc. Dip. Psychology - EMAIL: jennifer.bogan@gmail.com
Quote · 6 Nov 2010

Cool - thank you.

Quote · 6 Nov 2010

Thank you lancashiredates Smile

Life is a fatal disease, sexually transmissible - Virginity is carcinogenic! Ask here for vaccine.
Quote · 7 Nov 2010

Thank you very much!!

Very helpfull !

Go un noticed ? Please say so if my post helped you in any way.
Quote · 2 Sep 2011

This is a great tip - thanks!

Is there a way to set this up with a default value of "yes" whenever a new member signs up?  I tried using "yes" in the default area of the profile field setup, but it did not work.  Any guidance would be greatly appreciated.

Cheers - Jethro

Quote · 12 Dec 2011

Here's a down and dirty way, I haven't tested it so backup the file first.

 

Open /inc/classes/BxDolProfilesController.php and look for this:

 

                            if( $rRes ) {
                                  $iNewID = db_last_id();
   
                                   $this -> createProfileCache( $iNewID );

 

Then add this after it:

                           $sQuery = "UPDATE `Profiles` SET `MatchAlertMails` = 'Yes' WHERE `ID`= '$iNewID'";
                           db_res($sQuery);

 

BoonEx Certified Host: Zarconia.net - Fully Supported Shared and Dedicated for Dolphin
Quote · 12 Dec 2011

 Sweet!  Thanks so much - works perfectly.

Here's a down and dirty way, I haven't tested it so backup the file first.

 

Open /inc/classes/BxDolProfilesController.php and look for this:

 

                            if( $rRes ) {
                                  $iNewID = db_last_id();
   
                                   $this -> createProfileCache( $iNewID );

 

Then add this after it:

                           $sQuery = "UPDATE `Profiles` SET `MatchAlertMails` = 'Yes' WHERE `ID`= '$iNewID'";
                           db_res($sQuery);

 

 

Quote · 12 Dec 2011

hmmm. doesn't work. d 7.0.0.8.

made all changes (but in db i made "no" in all profiles by default), at first all worked, but now doesn't find any matches. Finds only 3 users that checked "yes" in "Receive Match Alert Mails"  and nobody more and i don't recieve cupid mail about new user that should match me.

and another question: if user checks "no"  (in "Receive Match Alert Mails") will other users recieve match mails about him or not?

sorry for my bad english.

Quote · 7 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.