- Go to the specific site's Dashboard and click
Users → Export User Data
.
- Select the following user meta fields to export:
- Description
- First name
- Last name
- LDAP login
- Nickname
- Change format to CSV.
- Export and download the resulting CSV file.
- Go to the "SMC - Web Team" folder in Google Drive and open the spreadsheet named "Migration User Data."
- In the spreadsheet viewer, go to
File → Import
, click "Upload" and upload your CSV file. - For "Import action," select "Insert new sheet(s)". Click "Import". The resulting name should suffice.
- Add a
migrate_num_posts
column - Select the header row (should be first) and go to
View → Freeze Rows → Freeze 1 row
.
- Sort spreadsheet by the
ID
column
- Make sure you're working off of a development or staging site.
- If you see the "Debug" button in the admin bar, skip to step 6.
- Install and Network Activate the Debug Bar and Debug Bar Console plugins.
- Go to the site you wish to get user post number info for.
- Click the "Debug" button in the top right corner of the admin bar.
- Click "Console" in the Debug interface.
- Paste the contents of
user-post-nums.php
in the PHP input field. - Run by clicking "Run" in the upper right of the interface or just press
Shift + Enter
- Copy the second set of results (just the numbers)...
- ...double check and make sure the sheet is sorted by the
ID
column!... - ...and paste it into the
migrate_num_posts
column in your spreadsheet. - Make sure to double check the accuracy!
- In the sheet you just modified, sort by the
migrate_num_posts
column.
- Remove all the rows with a
migrate_num_posts
value of0
- Remove the row corresponding to the
admin
user. - Remove the
ID
,migrate_num_posts
, anduser_registered
columns.
- Sort rows by the
ldap_login
column
- Select and copy all the values from the
user_login
column in the rows whereldap_login
equalsTRUE
- On the Live Rackspace site, go to the Dashboard for the site you're working on.
- Go to
Users → Add User
. - Paste the
user_login
values into the "Add Bulk Users" field. They should already be separated by newlines. - Make sure each will be added as a Subscriber.
- Submit by clicking the "Add Bulk Users" button.
- Remove the
ldap_login
column from the spreadsheet.
- After submitting the list of LDAP users, it's likely that some will not be found in the directory. You'll be notified about which users didn't make it. Don't navigate away from this page!
- Update the "Master SMC WP Network User List" accordingly
LDAP?
equalsy
Added
equalsy
- In your spreadsheet, select all the rows corresponding to the users that were successfully added.
- Press delete. The values in the rows will be deleted but the empty rows will remain.
- Sort any column so that all the empty rows appear grouped together at the top or bottom of the sheet. Select them all and go to
Edit → Delete rows…
(where the range of rows will appear at the end of the option) - Remove the
ldap_login
column. - Only the non-LDAP users and the users that were't found in the LDAP directory should remain in the spreadsheet.
- In the spreadsheet:
File → Download as → Comma-separated values (.csv, current sheet)
- In the site Dashboard, go to
Users → Import from CSV
. - Upload the CSV file you just created.
- Check the "Password nag" box.
- Import.
- Profit!