Title: switching to admin_user through an http:// command
Last modified: August 30, 2016

---

# switching to admin_user through an http:// command

 *  Resolved [gverhaeg](https://wordpress.org/support/users/gverhaeg/)
 * (@gverhaeg)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/switching-to-admin_user-through-an-http-command/)
 * Hello,
 * All of my member have the admin tool bar disabled.
    So, when I’m logged in admin,
   and I switch to a subscriber user, I can’t swtich back to admin. So, I create
   a persnal link in my Menu to activate an ‘[http://www.mysite/wplogin.php?action=switch_to_olduser=user_admin&#8217](http://www.mysite/wplogin.php?action=switch_to_olduser=user_admin&#8217);
   command.
 * But the syntaxe isn’t correct.
 * Could you help me?
    Many thanks
 * [https://wordpress.org/plugins/user-switching/](https://wordpress.org/plugins/user-switching/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [John Blackbourn](https://wordpress.org/support/users/johnbillion/)
 * (@johnbillion)
 * WordPress Core Developer
 * [10 years, 10 months ago](https://wordpress.org/support/topic/switching-to-admin_user-through-an-http-command/#post-6386299)
 * > So, when I’m logged in admin, and I switch to a subscriber user, I can’t swtich
   > back to admin.
 * In this situation, you can find the “Switch back” link either in the footer of
   your site, or, if you have it enabled, in the “Meta” sidebar widget.
 * Failing that, there’s always a “Switch back” link on the login screen if you 
   manually navigate to example.com/wp-login.php
 * John
 *  Thread Starter [gverhaeg](https://wordpress.org/support/users/gverhaeg/)
 * (@gverhaeg)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/switching-to-admin_user-through-an-http-command/#post-6386315)
 * John,
    Excatly, I can’t switch back to admin because I’m logged to a subscriber
   user who have the admin tool bar disabled and no side bar was displayed. It’s
   just a simple user with no rights. I can find the following “Switch back” link
   in the footer of my site: [http://www.xit745.ovh/xit745/wplogin.php?action=switch_to_olduser&wponce=6be7e9e631&redirect_to=http://www.xit745.ovh/xit745/](http://www.xit745.ovh/xit745/wplogin.php?action=switch_to_olduser&wponce=6be7e9e631&redirect_to=http://www.xit745.ovh/xit745/)
   What is 6be7e9e631 ???
 * Another method to solve my problem is to display the admin tool bar for each 
   user, but I would like to hide the possibility to update the profil user an to
   go in the dashboard.
 *  Plugin Author [John Blackbourn](https://wordpress.org/support/users/johnbillion/)
 * (@johnbillion)
 * WordPress Core Developer
 * [10 years, 10 months ago](https://wordpress.org/support/topic/switching-to-admin_user-through-an-http-command/#post-6386329)
 * > What is 6be7e9e631 ???
 * This is a WordPress security token called a nonce. It prevents other users form
   being able to trick you into performing administrative actions.
 * It’s strange that there is no link in the footer of your site. If your footer
   contains a call to `wp_footer()` then it should show up.
 * Failing that, if you want to add your own “Switch back” link somewhere, then 
   give the following code a try.
 *     ```
       <?php
       if ( $old_user = user_switching::get_old_user() ) {
       	$url = user_switching::switch_back_url( $old_user );
       	echo '<a href="' . esc_url( $url ) . '">Switch back</a>';
       }
       ?>
       ```
   

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘switching to admin_user through an http:// command’ is closed to new 
replies.

 * ![](https://ps.w.org/user-switching/assets/icon.svg?rev=3193956)
 * [User Switching](https://wordpress.org/plugins/user-switching/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/user-switching/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/user-switching/)
 * [Active Topics](https://wordpress.org/support/plugin/user-switching/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/user-switching/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/user-switching/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [John Blackbourn](https://wordpress.org/support/users/johnbillion/)
 * Last activity: [10 years, 10 months ago](https://wordpress.org/support/topic/switching-to-admin_user-through-an-http-command/#post-6386329)
 * Status: resolved