To make adding referrer as an option at registration page.
Open register template,
FIND:
Code:
<input type="text" class="bginput" name="referrername" value="$referrername" size="50" maxlength="250" />
BELOW, ADD:
Code:
<br><input type="checkbox" name="addreferrer" value=""> Add $referrername to your buddylist?
Then from amykhar's hack,
REPLACE:
Code:
if($referrer)
{
// Put it in the database.
$DB_site->query("
UPDATE " . TABLE_PREFIX . "usertextfield
SET buddylist = '" . addslashes($testreferrerid[userid]) . "'
WHERE userid = $userid
");
}
WITH:
Code:
if ($referrer AND $_POST['addreferrer'])
{
// Put it in the database.
$DB_site->query("
UPDATE " . TABLE_PREFIX . "usertextfield
SET buddylist = '" . addslashes($testreferrerid[userid]) . "'
WHERE userid = $userid
");
}
Did not tested