views:

36

answers:

2

Hi,

is there any way to chekc if a user with a special id is online in Wordpress?

+1  A: 

I think the function you want is is_user_logged_in. Maybe try

wp_set_current_user($id, $name = '')

To set the current user by id, and then check if they are logged in using

is_user_logged_in()

http://codex.wordpress.org/Function_Reference/wp_set_current_user

http://codex.wordpress.org/Function_Reference/is_user_logged_in

jkeesh