• Resolved nityac

    (@nityac)


    I have seven sites set up in a Multisite scenario. If I use the plugin to import users to Blog 1, when I try to use the CSV file to import an overlapping batch of users across Blogs 2 – 7 it says, “No user was successfully imported.”

    Is it possible for me to just import the usernames? If so, how? I don’t need to reset passwords or emails every time, just need to get sometimes overlapping batches of users added.

    https://www.ads-software.com/extend/plugins/import-users-from-csv/

Viewing 15 replies - 1 through 15 (of 20 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Are you trying to import them per site or on the Network Users page?

    The plugin may not be multisite capable.

    Thread Starter nityac

    (@nityac)

    Trying to add them per site. I’d be game to add them to the network users page, though. Is there a plug-in you know of that would allow me to assign users across Blogs 1 – 7 after I’ve added them to network users?

    The thoughts of typing out some 800 users per blog makes me want to cry.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Assign all of them the same role to all sites?

    That is everyone is a …

    subscriber on Blog 1
    editor on Blog 2
    Admin on Blog 3
    subscriber on Blog 4

    etc etc?

    Because THAT, yes.
    * https://www.ads-software.com/extend/plugins/multisite-user-management/

    Well, it is not optimized for use on a multisite. Since the users already exist in the database, they will not be added again.

    But there is a solution.
    If you add fields like ‘wp_5_capabilities’ with the value ‘a:1:{s:10:”subscriber”;s:1:”1″;}’ e.g. in your csv file the user will be added to the corresponding blogs.
    My example will give the user the role subscriber for the blog which ID is 5. Just add one field per blog, so wp_3_capabilities, wp_20_capabilities, etc.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Since the users already exist in the database, they will not be added again.

    Wait … what? *rereading*

    If I use the plugin to import users to Blog 1, when I try to use the CSV file to import an overlapping batch of users across Blogs 2 – 7 it says, “No user was successfully imported.”

    OH! OH OH!

    Duh. I’m an idiot. Sorry.

    Get https://www.ads-software.com/extend/plugins/multisite-user-management/

    That will let you add them as subscribers to all sites.

    Thread Starter nityac

    (@nityac)

    Thanks so much for the feedback.

    Ulrich, I’m about to attempt what you’ve outlined: if that’s the case, where can I do the CSV import from? Any of the blogs?

    Thread Starter nityac

    (@nityac)

    Actually, just tried this and it did the trick.

    HOORAY! Thank you, Ulrich. No tears over adding 800 users x 7 blogs.

    Thread Starter nityac

    (@nityac)

    One last question: I just added a CSV of users to a particular blog. The blog is showing that there are (2) editors, but not listing the editors I added. (The whole section is just blank.)

    Additionally, the users DO show up in the network admin.

    Any thoughts?

    @ipstenu: No problem!

    @nityac: what value did you use to add the editors?
    ‘a:1:{s:6:”editor”;s:1:”1″;}’?

    Thread Starter nityac

    (@nityac)

    Thanks, Ulrich.

    Not to be totally stupid here but: is that a string I need to add somewhere in the code for the blog or a string I need to add to the CSV file?

    I added a column ‘wp_5_capabilities’ and set everyone in that column to ‘Author’ via text.

    Thanks,
    Nitya

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    The s:6 in that bit is string length.

    If you add them as author, it should be the same though…

    You should set the column content to ‘a:1:{s:6:”editor”;s:1:”1″;}’ instead of ‘Author’.

    And , as Ipstenu wrote, s:6 bit is a string length (the length of the string ‘editor’ is 6). So, for subscribers, you would set it to ‘a:1:{s:10:”subscriber”;s:1:”1″;}’.

    Hi there, I really like the plugin but I’m also having trouble batch uploading users to a WP network.

    I am trying to upload a number of users as subscribers to one blog only on a network install.

    Going to the dashboard for the blog in question, I tried uploading the following test CSV:

    user_login,user_email,user_pass,first_name,last_name,role
    username,[email protected],pass,Fn,Sn,'a:1:{s:10:"subscriber";s:1:"1";}'

    This does appear to create a user:

    • the subscriber count for that blog shows (1)
    • I can also log in with that user’s details

    But

    • the username does not appear in the list of all users (or of subscribers) for that blog.
    • and that user cannot access their profile to change it.

    Any ideas what I’m doing wrong?

    Thanks

    Matthew

    @mrmjct: You should name the role field ‘wp_5_capabilities’ instead of ‘role’. where 5 is the blog_id. So ‘wp_10_capabilities’ if the blog_id is 10.

    Thanks Ulrich. My mistake – you had mentioned that in this list that’s fixed it now.

Viewing 15 replies - 1 through 15 (of 20 total)
  • The topic ‘[Plugin: Import Users from CSV] Import Existing Users with Multisite’ is closed to new replies.