Hello,
I saw that is possible to connect a user from a PHP script with something like that . When the user login into my site I also connect him on the forum
The problem is that i haven't found a way to login the user to XF without checking user password (Can cause Mysql querying issues for a high traffic site!), any way to login the user just with his user_id ?
Thanks
Sorry for my bad english
I saw that is possible to connect a user from a PHP script with something like that . When the user login into my site I also connect him on the forum
Code:
[...]
$ip = $XF->request->getIp();
$service = $XF->service('XF:User\Login', $input, $ip);
$user = $service->validate($password, $error);
//completeLogin
$XF->session->changeUser($user);
XF::setVisitor($user);
$XF->repository('XF:SessionActivity')->clearUserActivity(0, $ip);
$XF->repository('XF:Ip')->logIp;
The problem is that i haven't found a way to login the user to XF without checking user password (Can cause Mysql querying issues for a high traffic site!), any way to login the user just with his user_id ?
Thanks
Sorry for my bad english