Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#16 auto login after auto activation

XOOPS_2.0.x
open
nobody
Core (214)
5
2012-09-25
2003-04-02
Martin Kutschker
No

Hi!

A new user activation type would be cool: "Activate and
login automatically". Having to login just after you
registered is IMHO an unnecessary step. But some folks
may like it.

A hacky approach:

// auto login after auto activate/register
if ($xoopsConfigUser['activation_type'] == 3) {
// HACK - start
$HTTP_POST_VARS['uname'] = $uname;
$HTTP_POST_VARS['pass'] = $pass;
include_once XOOPS_ROOT_PATH.'/include/checklogin.php';
// HACK - end

exit();

}

Converting the login (session creating) into a
function/method would improve the situation.

Masi

Discussion