WordPress.org

Forums

WP Author Slug
[resolved] How to uninstall properly? (2 posts)

  1. Liesl Fawcett
    Member
    Posted 4 years ago #

    Hi, I uninstalled this plugin because I no longer want to use it and all the slugs remained changed. How can I get the usernames back? I no longer want the "sanitized version" of the user's display name.

  2. KOB
    Member
    Posted 4 years ago #

    Hi Liesl,

    you can get the usernames back by running the following:

    global $wpdb;
    $users = (function_exists('get_users')) ? get_users() : get_users_of_blog();
    
    	foreach ( $users as $user ){
    
    			$wpdb->update(
    				$wpdb->users,
    				array( 'user_nicename'	=>	sanitize_title($user->user_login) ),
    				array( 'ID'				=>	$user->ID )
    			);
    	}

    I'm sorry the plugin didn't work out for you. I'll update the plugin with an uninstall routine as soon as I have the time.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP Author Slug
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic