Author Topic: Need the user to automatically login after registration  (Read 726 times)

Offline Ross

  • Jr. Member
  • **
  • Posts: 9
    • View Profile
Need the user to automatically login after registration
« on: 15/October/2010, 08:16:43 AM »
Hello,

This can be realized with standard Joomla registration form by changing
/components/com_user/controller.php , function register_save()

and replacing $this->setRedirect('index.php', $message); with

Code: [Select]
$usersipass['username'] = $user->get('username');
      $usersipass['password'] = $password;
      $mainframe->login($usersipass);
      $mainframe->redirect( 'index.php' );
}


Howewer for nBill form it does not work. Itried all types of Advanced PHP code for the form.
How this important thing can be realized?

Offline Ross

  • Jr. Member
  • **
  • Posts: 9
    • View Profile
Re: Need the user to automatically login after registration
« Reply #1 on: 15/October/2010, 09:07:56 AM »
Pff... found

/administrator/components/com_nbill/framewrork/interop/nbill.interop.joomla_1_5.php

Added stuff at the end of
function create_user($name, $username, $password, $email)

P.S.: An idea - to make this as an option in order form.

Offline netshine

  • Administrator
  • Hero Member
  • *****
  • Posts: 4,955
    • View Profile
Re: Need the user to automatically login after registration
« Reply #2 on: 15/October/2010, 09:27:13 AM »
Thank you for the suggestion, and please bear in mind that you will need to re-apply your customisation whenever you upgrade nBill.