Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
How do i check if a user is already logged ?
How do i check if a user is already logged ? and he has open valid session with my vanilla forum. The GDN_WhosOnline table does not store the session status. Is there some thing called, Idle time out for user?
0
Comments
if (Gdn::Session()->UserID === 0) { // user is not logged in }
$Session = Gdn::Session(); if ($Session->IsValid()){ //user is logged in }
if (Gdn::Session()->IsValid()) { ... }
No need to assign $Session
Vanilla Forums COO [GitHub, Twitter, About.me]