Forum Replies Created
-
AuthorPosts
-
Vladimir
KeymasterHi @wp.network,
Thanks for this remind and definitely useful suggestions. No these features are still not realized. I confirm that I will work on them this year.
26/04/2018 at 16:10 in reply to: Limit user to changing a single page & add events through multiple plugins #4805Vladimir
KeymasterHi Arie,
Code for user with 2 roles to exclude from the edit restrictions 2 mentioned custom post types may be similar to:add_filter('ure_restrict_edit_post_type', 'exclude_posts_from_edit_restrictions'); function exclude_posts_from_edit_restrictions($post_type) { $restrict_it = true; $current_user = wp_get_current_user(); if (!in_array('hetbakenbeheer', $current_user->roles) || !in_array('kerkdienstplanning', $current_user->roles)) { return $restrict_it; } $do_not_restrict = array('event', 'ctc-event'); if (in_array($post_type, $do_not_restrict)) { $restrict_it = false; } return $restrict_it; }
Vladimir
KeymasterArie,
Thanks for the help with isolating this conflict between 2 plugins.
Vladimir
KeymasterCan you please test development version 4.45.b2?
It’s available after login from the same Download” page.Vladimir
KeymasterArie,
Perfect. Now, I reproduced a PHP error trying to open restricted pages list having active “ACF Better Search” plugin. I will work on a workaround.
Vladimir
KeymasterArie,
Thanks for the information. I just wanted to recommend you, if you have some unused plugins activated try to deactivate them. It will free some memory and may resolve an issue.
Before I will start tests with “ACF: Better Search”, what if to deactivate some other plugin(s), but leave ACF BS active instead? Will error 500 problem stay or go away? I
Vladimir
KeymasterHi Arie,
Right, it’s not the permissions issue. You will see ‘Not enough permissions’ or similar error message in that case. HTTP 500 error code is a server side error. The most probable reason is a script execution timeout or ‘not enough memory’ issue. It will be good if you can look at the server system logs for the related error message.
Do you have a huge quantity of posts at your site?
Vladimir
KeymasterTo @kmeronuk,
You came to a right conclusion. I added new paragraph to admin menu documentation page. It explains a reason and includes a workaround.
Vladimir
KeymasterUser Role Editor does not make any special efforts on custom user capabilites created by other plugins. ‘gravity_forms_addonname_uninstall’ user capability is registered by active Gravity Forms add-on and should be used by Gravity Forms or/and related GF add-on.
URE helps you to add such custom user capability to a role by your selection. URE saves capability with role together in the database when you turn it on for a role. That’s it.
I made a quick search through the GF code and one of GF add-on I have. It seems, on the 1st glance, that this capability ‘gravity_forms_addonname_uninstall’ is never used.
Vladimir
KeymasterHi Michael,
I’m sorry about so huge delay with response. I missed you question somehow.
User Role Editor just modifies role here (according to your description) and nothing more. GF plugin itself should check a capability and prohibit not allowed actions. It’s better to address this question to Gravity Forms support 1st.
Vladimir
Keymaster1st, $user_role and $user variables are not defined in these code lines:
if ( $user_role == ‘customer’ ) { $user->remove_role( ‘new-web’ );
You should start from getting current user:
$user = wp_get_current_user(); if(!$user) { return; }
Then check if current user is not administrator.
Then make manipulations with user role.
If you use $user->add_role(), $user->remove_role(), there is no need to use wp_update_user().Vladimir
KeymasterI include links to the documentation from the very 1st answer. But it seems that you ignore them for some reason. Please open this thread on site in a browser and go to the documentation links provided. Then ask questions if you will still have them.
Searching/filtering adds new arguments/parameters to URL. When you use “Block not selected” model, only apparently selected menu links are allowed. The same link with additional argument(s) is counted as not selected, and thus, blocked. Take into account that “Block not selected” model is more restrictive comparing to the “Block Selected”, where URE block only links which you selected and does not decide itself what to block.
Vladimir
KeymasterThis screenshot just confirms my assumption. It is exactly the case addressed here. Try to follow to this recommendations:
1)You can change model from “block not selected” to “block selected” and invert menu items selection by pressing ‘Shift’ and click on the top checkbox.
or
2) You can add URL arguments added by search in the Media Library to the admin menu “URL Parameters White List” for this menu item.Vladimir
KeymasterHi Max,
Good idea to realize. Thanks.
Vladimir
KeymasterHi Max,
URE works with the single (current) network at this point of time. When URE is network activated its settings are saved for the main site of the current network.
Let me know if you will find any issue during your milti-network tests.
-
AuthorPosts