changed user data

  • Posts: 44
  • Thank you received: 0
12 years 7 months ago #47766

if I loaded the user using
$user = hikashop_loadUser(true);
and then
$user->user_partner_activated = 1;
to activate partner status however the user partnership status is not activated. is there a way to change the attributes of the user object and have them stick

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
12 years 7 months ago #47923

That just set the variable in the object of the current page. It doesn't save the information in the database.
For that, you will have to do like that :

$class = hikashop_get('class.user');
$updateObject = null;
$updateObject->user_id = hikashop_loadUser();
$updateObject->user_partner_activated = 1;
$class->save($updateObject);

Please Log in or Create an account to join the conversation.

Time to create page: 0.057 seconds
Powered by Kunena Forum