Viewing 15 replies - 1 through 15 (of 16 total)
  • Thread Starter Austin

    (@austyfrosty)

    For the time being I have implemented this code in my core plugin:

    function extendd_dot_com_remove_wpmandrill_dashboard() {
    	if ( class_exists( 'wpMandrill' ) ) {
    		remove_action( 'wp_dashboard_setup', array( 'wpMandrill' , 'addDashboardWidgets' ) );
    		if ( current_user_can( 'manage_options' ) ) {
    			add_action( 'wp_dashboard_setup', array( 'wpMandrill' , 'addDashboardWidgets' ) );
    		}
    	}
    }
    add_action( 'admin_init', 'extendd_dot_com_remove_wpmandrill_dashboard' );
    

    It removed the dashboard widget for users that can’t manage_options

    Hey.

    Thanks for the suggestion. That will be included in the next release.

    I am a bit of a minimalist, so I’d love the option of whether or not to show the dashboard widget. Would this be possible to add in WPMandrill settings?

    Thread Starter Austin

    (@austyfrosty)

    @baritoneuk Go up to your screen options and unckeck Mandrill.

    Screen options only gets rid of the dashboard for the current user. When I build WordPress websites for clients I want to make sure the dashboard is as free as possible from clutter. The majority in fact probably all of our clients aren’t going to want to see the Mandrill dashboard widget. The problem with the screen options feature in WordPress is that it relies on the user knowing that it exists and then deselecting the widgets.

    My view is that plugins should always have an option as to whether you want the dashboard widget displayed or not. I’m glad to see that Yoast saw the light last year- http://yoast.com/wordpress-dashboard-widgets/

    Thread Starter Austin

    (@austyfrosty)

    Use my function above to remove it.

    Ah, just realised it was you who provided the code and I had forgotten to thank you!

    I added the code yesterday and my dashboard has been returned to blissful minimalism! 🙂

    Still forgot to thank you…

    Thanks!

    Thread Starter Austin

    (@austyfrosty)

    🙂

    Ovidiu

    (@ovidiu)

    Would it be possible to restrict the widget to only show stats for the API key used on that blog and not for the whole Mandrill account?

    Plugin Author MC_Will

    (@mc_will)

    @ovidiu: Sorry, It’s not possible at the moment.

    @mc_will – any thoughts on making the dashboard widget optional or at least having an option to switch it off?

    Plugin Author MC_Will

    (@mc_will)

    Yes Sir!

    In the meantime you can use Austin’s hack.

    @mc_will: so I’ll have to create an account for each WP site I manage? I thought I’d use one Mandrill account for all and then probably have to upgrade from the free service to the paid tier.
    So do you plan on making this option available sometime in the future or do you suggest I go and get a Mandrill account for each site?

    Plugin Author MC_Will

    (@mc_will)

    Right now, there’s no way we can filter by API key, not in the plugin but in our API.

    I’ve added this request to our road map but I don’t know if it will be available anytime soon.

    I’ll keep this thread updated.

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Dashboard Widget’ is closed to new replies.