when i send the registration form it does go into the database, but the page says :
Notice: Undefined variable: userdetails in /www/usersc/scripts/during_user_creation.php on line 28
NULL
Line 28 being that line we just added.
And only the registrant gets an email.
$db->update('users',$theNewId,['phone'=>Input::get('phone')]);
$db->update('users',$theNewId,['challenges'=>Input::get('challenges')]);
$db->update('users',$theNewId,['membership'=>Input::get('membership')]);
$db->update('users',$theNewId,['orig_chos_day'=>Input::get('orig_chos_day')]);
$db->update('users',$theNewId,['message'=>Input::get('message')]);
$db->update('users',$theNewId,['ecname'=>Input::get('ecname')]);
$db->update('users',$theNewId,['ecphone'=>Input::get('ecphone')]);
dnd($userdetails);
$params = array(
'sitename' => $settings->site_name,
'fname' => $userdetails->fname,
'lname' => $userdetails->lname,
'email' => rawurlencode($userdetails->email),
'phone' => $userdetails->phone,
);
$to = rawurlencode("my@mail.com");
$subject = 'New Registration!';
$body = email_body('_email_newuser.php',$params);
email($to,$subject,$body);
Notice: Undefined variable: userdetails in /www/usersc/scripts/during_user_creation.php on line 28
NULL
Line 28 being that line we just added.
And only the registrant gets an email.
$db->update('users',$theNewId,['phone'=>Input::get('phone')]);
$db->update('users',$theNewId,['challenges'=>Input::get('challenges')]);
$db->update('users',$theNewId,['membership'=>Input::get('membership')]);
$db->update('users',$theNewId,['orig_chos_day'=>Input::get('orig_chos_day')]);
$db->update('users',$theNewId,['message'=>Input::get('message')]);
$db->update('users',$theNewId,['ecname'=>Input::get('ecname')]);
$db->update('users',$theNewId,['ecphone'=>Input::get('ecphone')]);
dnd($userdetails);
$params = array(
'sitename' => $settings->site_name,
'fname' => $userdetails->fname,
'lname' => $userdetails->lname,
'email' => rawurlencode($userdetails->email),
'phone' => $userdetails->phone,
);
$to = rawurlencode("my@mail.com");
$subject = 'New Registration!';
$body = email_body('_email_newuser.php',$params);
email($to,$subject,$body);