Select Menu
Select Menu

MyBloggerTicks

ShoutMeLoud

Wisata

Culture

Transportasi Tradisional

Rumah Adat

Bali

Pantai

Seni Budaya

Kuliner

» » How to Destroy a User Session in WordPress


BloggBuzzer 07:09 0

Source : How to Destroy a User Session in WordPress
Published On : September 01, 2015 at 07:31PM
By : Agbonghama Collins

Below is a PHP function that can programmatically logout or destroy a user session in WordPress taking the user ID as an argument. /** * Destroy the session of a user. * * @param int $user_id */ function pp_destroy_user_session( $user_id ) { // get all sessions for user with ID $user_id $sessions = WP_Session_Tokens::get_instance( $user_id […]



For More Go to : w3guy - Diary of a Geek

«
Next
Newer Post
»
Previous
Older Post

No comments

Leave a Reply