Forum Replies Created

Viewing 15 posts - 121 through 135 (of 2,506 total)
  • Author
    Posts
  • in reply to: Ability to edit permissions per CPT #8162
    Vladimir
    Keymaster
    in reply to: User Profile Fields #8158
    Vladimir
    Keymaster

    In the provided piece of code the key line is missed:

    
    add_action('admin_init', 'user_profile_fields_disable');
    

    It links your function to the hook which executes it.

    Also pay attention that JavaScript code disables only input fields. It can not disable any other visible element. If you wish to hide some element on a page you should use another jQuery code, like

    
    jQuery('#div_id').hide();
    
    Vladimir
    Keymaster

    OK.

    Vladimir
    Keymaster

    Is it possible to look on your site (development/stage copy preferred) with admin privileges? If Yes, send credentials to support [at-sign] role-editor.com

    Vladimir
    Keymaster

    Does your user have WordPress built-in ‘administrator’ role?

    URE automatically grants full access to itself to the ‘administrator’ role and hides itself from other users with access to the plugins list, who don’t have ‘ure_manage_options’ capability.

    in reply to: User Profile Fields #8149
    Vladimir
    Keymaster

    Send the link to a new code version to support [at-sign] role-editor.com

    in reply to: User Profile Fields #8147
    Vladimir
    Keymaster

    Hi,

    Syntax error is at the prev line – missed closing bracket ‘)’ after (‘custom_role’). It should be:

    
        if (current_user_can('custom_role')) {
          add_action( 'admin_footer', 'user_profile_fields_disable_js' );
        }      
    
    
    Vladimir
    Keymaster

    Hi Elizabeth,

    You have to deactivate any active version of URE before try activate another one.
    If you accidentally lost URE permissions – deactivation/activation of URE helps usually.

    in reply to: User Profile Fields #8142
    Vladimir
    Keymaster

    If you will need further help, send or share via Google Drive a modified functions.php file. I will check its syntax.

    in reply to: User Profile Fields #8141
    Vladimir
    Keymaster

    I see 2 possible problems in the code above:
    1) Look if single quote “‘” is not replaced at your copy with other characters;
    2) at the JavaScript code line
    var fields_to_disable = ['role', 'facebook', 'twitter', 'additional_profile_urls', 'wp-user-avatar-existing,];
    there is a syntax error. Replace the ‘,’ at the end with missed “‘” (closing single quote) character, like below:
    var fields_to_disable = ['role', 'facebook', 'twitter', 'additional_profile_urls', 'wp-user-avatar-existing'];

    Vladimir
    Keymaster

    You can exclude role ‘board_member’ from all user role selecting drop-down lists exactly for the user with role ‘coordinator’ using the code below:

    
    add_filter('editable_roles', 'ure_exclude_role', 10, 1);
    function ure_exclude_role( $roles ) {
        
        $user = wp_get_current_user();
        if ( empty( $user ) || empty( $user->roles ) ) {
            return $roles;
        }
        
        if ( !in_array( 'coordinator', $user->roles ) ) {
            return $roles;
        }
    
        // Remove board_member role from all dropdown user roles lists
        if ( isset( $roles['board_member'] ) ) {
             unset( $roles['board_member'] );
        }
    
        
        return $roles;
    }
    

    Also you can fully exclude roles and users with those roles from the point of view user with coordinator role with the help of “Other roles access” add-on:

    Other roles access management

    in reply to: Adding capabilies are not saved on user group #8128
    Vladimir
    Keymaster

    Hi,

    There would be 2 possible problems:
    1) Changes are not saved to any role due to JavaScript error. Check the browser JavaScript console if it contains error messages after “Users->User Role Editor” page opening or after click on the “Update” button.
    2) Role which you try to change is re-created by some plugin on a fly for every user requests. You may test this deactivating temporally all plugins except URE and update a role again.

    What case is yours?

    Vladimir
    Keymaster

    If look at the file class-gf-mailchimp.php, line #119, you will see:

    /**
    * Defines the capabilities needed for the Mailchimp Add-On
    *
    * @since 3.0
    * @access protected
    * @var array $_capabilities The capabilities needed for the Add-On
    */
    protected $_capabilities = array( 'gravityforms_mailchimp', 'gravityforms_mailchimp_uninstall' );

    So Mailchimp menu item is protected by ‘gravityforms_mailchimp’ user capability.

    Vladimir
    Keymaster

    Hi,

    In order to help you I need access to this add-on copy. If it’s applicable share .zip with support [at-sign] role-editor.com via Google Drive or DropBox. I use such software locally and in the investigation purpose only.

    Vladimir
    Keymaster

    Hi,

    Do you use this plugin for integration with MailChimp?

Viewing 15 posts - 121 through 135 (of 2,506 total)