X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Ffilter%2Fuser_filter.php;h=1040aaee4e5f280d7c3103a9b4156553ffc558d9;hp=95f91b3df5aa24147397046fa5f009637200faec;hb=b0ed0547ba277e815ca38b3333b191149a88019c;hpb=8ed6af64e47d41cb94b4f9b57a046f3d9089375f diff --git a/inc/filter/user_filter.php b/inc/filter/user_filter.php index 95f91b3df5..1040aaee4e 100644 --- a/inc/filter/user_filter.php +++ b/inc/filter/user_filter.php @@ -147,5 +147,31 @@ function FILTER_ADD_USER_DATA_CONVERT_SQL_COLUMNS ($sql) { return $sql; } +// Filter for handling user subids (called by referral link) +function FILTER_HANDLE_USER_SUBID ($filterData) { + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Called!'); + + // Return filter data + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Done!'); + //* NOISY-DEBUG: */ print __FUNCTION__.':filterData=
'.print_r($filterData,true).'
'; + return $filterData; +} + +// Filter for adding SQL columns on user registration for subid +function FILTER_SUBID_USER_REGISTRATION_ADD_SQL_COLUMNS ($filterData) { + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Called!'); + + // Is the sub id set in session? + if (isSessionVariableSet('subid')) { + // Okay, add subid here + addExtraRegistrationColumns(', `subid`'); + addExtraRegistrationData(", '" . getSession('subid') . "'"); + } // END - if + + // Return filter data + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Done!'); + return $filterData; +} + // [EOF] ?>