1
Coding / How to get credits for Referrals (Using Referrals Mod)
« on: November 12, 2007, 04:59:01 am »
Many people (like me) want a referral mod in which we can get credits from. I searched around and couldnt find it here, so I looked elsewhere. Anyways, I found something that will work amazingly!
First, install the referrals mod:
http://custom.simplemachines.org/mods/index.php?mod=836
After installing it the usual way through the package manager, use your ftp program to download Register.php from /Sources.
Once you have that file, open it with an editor (like notepad) and find the following line:
Remove the two slashes and the space after it (// ) and set the 100 to whatever amount of credits you want your members to receive when the referral is signed up. Save the file and upload it to your Sources Folder. (You should back up the other one incase rather than over writing it) Now, when someone is referred using their referral ID, they will get credits and it will show the number of referrals in their profile that they've gotten.
I posted this incase anyone wasn't aware that this could be done so easily!
First, install the referrals mod:
http://custom.simplemachines.org/mods/index.php?mod=836
After installing it the usual way through the package manager, use your ftp program to download Register.php from /Sources.
Once you have that file, open it with an editor (like notepad) and find the following line:
Code: [Select]
// updateMemberData((int) $_POST['referredby'], array('money' => 'money + 100',));
(the needed code is conveniently already in the mod)Remove the two slashes and the space after it (// ) and set the 100 to whatever amount of credits you want your members to receive when the referral is signed up. Save the file and upload it to your Sources Folder. (You should back up the other one incase rather than over writing it) Now, when someone is referred using their referral ID, they will get credits and it will show the number of referrals in their profile that they've gotten.
I posted this incase anyone wasn't aware that this could be done so easily!
