[英]How to track online users with Facebook login?
I am using timestamp to fetch online users with php 我正在使用时间戳来获取php的在线用户
$time=time()-5;
$result = mysqli_query($con,"SELECT * FROM users WHERE timestamp>$time ");
How can i do this if the user logged in with facebook login plugin? 如果用户使用facebook登录插件登录,我该怎么做?
online_presence The user's Facebook Chat status . online_presence用户的Facebook聊天状态 。
Returns a string, one of active, idle, offline, or error
(when Facebook can't determine presence information on the server side). 返回一个字符串,一个是
active, idle, offline, or error
(当Facebook无法确定服务器端的状态信息时)。 The query does not return the user's Facebook Chat
status when that information is restricted for privacy reasons 当出于隐私原因限制该信息时,查询不会返回
user's Facebook Chat
状态
TO GET IN PHP
through Query. 通过Query获取
PHP
。
$result = mysqli_query($con,"SELECT * FROM users WHERE online_presence
IN ('active', 'idle') AND timestamp>$time ");
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.