Support » Plugin: User Role Editor » [Plugin: User Role Editor] Cannot use Export without also selecting Import

  • Hello,

    I’ve just set up this plugin for the first time. Seems like it’s going to be *very* helpful 🙂

    I did find one thing that I wish would work differently. Seems I cannot select the Export option without also selecting the Import option if I want the Export option available. I would like to be able to use the Export option without the Import option.

    Maybe I’m doing something wrong but I tried many different selections to make this work and couldn’t make it happen.

Viewing 1 replies (of 1 total)
  • Plugin Author Vladimir Garagulia



    You are right. WordPress core code is built this way. If we look at wp-admin/menu.php at line # 206 we can see:

    $menu[75] = array( __('Tools'), 'edit_posts', 'tools.php', '', 'menu-top menu-icon-tools', 'menu-tools', 'div' );
    	$submenu['tools.php'][5] = array( __('Tools'), 'edit_posts', 'tools.php' );
    	$submenu['tools.php'][10] = array( __('Import'), 'import', 'import.php' );
    	$submenu['tools.php'][15] = array( __('Export'), 'import', 'export.php' );

    Thus, in order to have ‘Export’ menu available user should have ‘import’ capability. But if we look at the begin of wp-admin/export.php we see:

    if ( !current_user_can('export') )
    	wp_die(__('You do not have sufficient permissions to export the content of this site.'));

    That is the ‘export’ capability is checked there. So this thing could be named a bug and reported to the WordPress developers, I think :).

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: User Role Editor] Cannot use Export without also selecting Import’ is closed to new replies.