[solved] Autologin after registration. 1.5.х, website - Joomla! Forum - community, help and support
hi! how make autologin after registration joomla 1.5.x ? saw many solutions joomla 1.0.x - 1.5.x there no
on site i'm using standard registration (without confirmation e-mail, field e-mail not necessarily) , want fill fields (username & password) users automatically become login
thks
on site i'm using standard registration (without confirmation e-mail, field e-mail not necessarily) , want fill fields (username & password) users automatically become login
thks
open file joomla_root/components/com_user/controller.php in text editor , go line 282.
comment out line $this->setredirect('index.php', $message);
and add after -
//$this->setredirect('index.php', $message);
$usersipass['username'] = $user->get('username');
$usersipass['password'] = $password;
$mainframe->login($usersipass);
$mainframe->redirect( 'index.php' );
now have clicked submit button username , password filled in , logged in front page.
if them redirected special welcome page, thank etc change line required page - e.g.
//$mainframe->redirect( 'index.php' );
$mainframe->redirect( 'index.php?option=com_content&view=article&id=45&itemid=53' );
comment out line $this->setredirect('index.php', $message);
and add after -
//$this->setredirect('index.php', $message);
$usersipass['username'] = $user->get('username');
$usersipass['password'] = $password;
$mainframe->login($usersipass);
$mainframe->redirect( 'index.php' );
now have clicked submit button username , password filled in , logged in front page.
if them redirected special welcome page, thank etc change line required page - e.g.
//$mainframe->redirect( 'index.php' );
$mainframe->redirect( 'index.php?option=com_content&view=article&id=45&itemid=53' );
Comments
Post a Comment