How to allow users in wordpress to switch between two assigned roles e.g. Candidate & Employer
Lets say you are logged in as “Candidate” and if you want to switch to “Employer” , you should then create a new user record with employer role and keep the candidate user_id in employer usermeta table as “switch_user_id” Suppose that candidate user_id is 4 and if you switch it will first check if “switch_user_id” … Read more