Here is the trigger I have found that is causing the issue:
Code:
$fname = rawurlencode('[firstname]');
$lname = rawurlencode('[lastname]');
$address1 = rawurlencode('[cb_addressline1]');
$address2 = rawurlencode('[cb_addressline2]');
$city = rawurlencode('[cb_city]');
$state = rawurlencode('[cb_state]');
$zipcode = rawurlencode('[cb_zip]');
$altmember_id = '[user_id]';
$enroll_date = rawurlencode(date('m/d/Y'));
$offer_code = rawurlencode('[cb_enteryourpromocodeifyouhaveone]');
$lati = '-41.0292';
$longi = '0.00';
$emailaddress = rawurlencode('[email]');
$phone = rawurlencode('[cb_primaryphone]');
$altphone = rawurlencode('[cb_secondaryphone]');
$zip4 = rawurlencode('[cb_zip4]');
$curl = curl_init();
curl_setopt($curl, CURLOPT_VERBOSE, 1);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
curl_setopt($curl, CURLOPT_TIMEOUT, 30);
curl_setopt($curl, CURLOPT_URL, 'https://mysite.com/script.php?type=ENROLL&website_id=TEST&fname='.$fname.'&mname&lname='.$lname.'&address1='.$address1.'&address2='.$address2.'&city='.$city.'&state='.$state.'&zipcode='.$zipcode.'&zip4='.$zip4.'&altmember_id='.$altmember_id.'&enroll_date='.$enroll_date.'&last_profile_update='.$last_profile_update.'&offer_code='.$offer_code.'&account_mask&lati='.$lati.'&longi='.$longi.'&emailaddress='.$emailaddress.'&phone='.$phone.'&altphone='.$altphone.'');
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
$Response = curl_exec($curl);
curl_close($curl);
$user = cbUser::getUserDataInstance( '[user_id]' );
$user->set( 'cb_rdcno', $Response );
$user->store();
Ultimately it enrolls the user in the master database and then sends the response to the cb_rdcno field. When I disable the trigger I see the password is hashed. The only trigger I am using is:
onAfterUserRegistration
method: PHP(create_function)
silent return.
Any idea why the password is getting changed when I am storing the user value?