10/03/2020 at 09:47 #6686
Just wanted to ask if it is possible to migrate all my user-roles from my test to live site. My plugin is currently activated only on my test site, and I would like to move everything over to the live site without going trough multiple user-roles again.
I’ve tried searching but did not find anything. Any kind of help would be appreciated!
Andrija10/03/2020 at 12:23 #6688
If you have not too much user roles you can use ‘Export/Import’ buttons to make this role by role. ‘Export’ button write currently selected role to the local file. ‘Import’ button imports role data from the selected file (previously exported).
This will resolve your task if you don’t care about data set for/by URE additional modules.10/03/2020 at 14:15 #6693
Thanks for the info. I have a lot of users, but I did get most if not all the permissions sorted through roles. So this will definitely save me some time. I would basically need to make sure all my settings are the same first, then export -> import the roles across the two sites, and finish everything up by assigning the users the appropriate roles.
Andrija11/03/2020 at 01:54 #6695
If you familiar with SQL and the tools like phpMyAdmin, it’s possible to export/import all user roles with less efforts. Suppose the database prefix is ‘wp_’.
1) Find the WordPress db record with user roles:
SELECT * FROM wp_options WHERE option_name='wp_user_roles';
2) Update all user roles at once:
UPDATE wp_options SET option_value='changed value here' WHERE option_id=NN LIMIT 1;
This post explains in details how and where WordPress stores user roles data.
Do you use any URE Pro additional modules at the test site?11/03/2020 at 09:59 #6696
Sorry for getting back to you so late. But yes, I do have some URE additional modules.
Activate Administrator Menu Access module
Activate “Create” capability for posts/pages/custom post types
Activate user access management to editing selected posts, pages, custom post types
Force custom post types to use their own capabilities
I’ll look at your post, as I’m familiar with SQL. Thanks for your help!
Andrija11/03/2020 at 13:52 #6697
In this case this is may be interesting for you too:
1) Base options saved by User Role Editor Pro:
SELECT * FROM wp_options WHERE option_name LIKE 'user_role_editor';
2) Data saved by URE add-ons:
SELECT * FROM wp_options WHERE option_name LIKE 'ure_%';
Before importing ure_posts_edit_access_data record to the live database take into account if posts/pages ID are the same at the source and targets databases.
- You must be logged in to reply to this topic.