Home  >  Q&A  >  body text

The number of logins shows nothing, why?

index.html

<p>Number of logins: {$Think.session.user_info.login_count}</p>

<p>Last time Login IP: {$Request.ip} Last login time: {:date("Y-m-d H:i:s",$Think.session.user_info.login_time)}</p>

User. In php

$user = UserModel::get($map);
if($user == null){
$result = 'The user was not found';
}else {
$status = 1;
$result = 'Verification passed, click [OK] to enter';
Session::set('user_id',$user->id);//User id
Session::set('user_info', $user->getData());//Get all user information
}


SarahSarah2625 days ago1497

reply all(1)I'll reply

  • Sarah

    Sarah2017-09-04 13:00:35

    Already know. This field is not set in the database. I didn’t see that the teacher has set these fields in Zhujuku

    reply
    0
  • ringa_lee

    Hey hey hey

    ringa_lee · 2017-09-05 09:25:09
  • Cancelreply