WordPress plugin containing modules to cleanup and customize wp-admin
Switch branches/tags
Nothing to show
Clone or download
Latest commit 78e1d13 Dec 11, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github 1.2.0 Aug 26, 2017
dist Update dist Aug 26, 2017
src FIX update-pagination module Sep 20, 2018
.editorconfig Let's get this intervention started Sep 14, 2016
.gitattributes Move .docs to .github Sep 15, 2016
.gitignore Let's get this intervention started Sep 14, 2016
CHANGELOG.md 1.2.0 Aug 26, 2017
LICENSE.md Update meta Jan 2, 2017
README.md Update README.md Nov 8, 2018
build.xml 1.0.1 Sep 22, 2016
composer.json Update description Jan 2, 2017
composer.lock Update dist Aug 26, 2017
intervention.php Update/s Mar 11, 2017
phpcs.xml Update/s Mar 11, 2017

README.md

Intervention

WordPress plugin containing modules to cleanup and customize wp-admin. Let's get rid of that admin panel we love so much.

Installation

Composer:

Recommended method/s;

Roots Bedrock and WP-CLI

$ composer require soberwp/intervention
$ wp plugin activate intervention

Roots Sage

$ composer require soberwp/intervention:1.2.0-p

Manual:

  • Download the zip file
  • Unzip to your sites plugin folder
  • Activate via WordPress

WP-CLI:

$ wp plugin install https://github.com/soberwp/intervention/archive/master.zip --activate

Requirements:

Usage

Import the namespaced function:

Place at the top of your themes functions.php file.


use function \Sober\Intervention\intervention;

if (function_exists('\Sober\Intervention\intervention')) {
    // now you can use the function to call the required modules and their params
    intervention('remove-menu-items', 'plugins', 'all');
}

Modules

Use function intervention() to use plugin modules.

Example functions.php file

intervention('remove-menu-items', ['themes', 'plugins'], ['editor', 'author']);

Click on a module below to view its usage documentation:

Quick Reference

  • add-acf-page
    intervention('add-acf-page', $config(string|array), $roles(string|array));

  • add-dashboard-item
    intervention('add-dashboard-item', $item(array));

  • add-dashboard-redirect
    intervention('add-dashboard-redirect', $route(string), $roles(string|array));

  • add-menu-page
    intervention('add-menu-page', $config(string|array), $roles(string|array));

  • add-svg-support
    intervention('add-svg-support', $roles(string|array));

  • remove-customizer-items
    intervention('remove-customizer-items', $items(string|array), $roles(string|array));

  • remove-dashboard-items
    intervention('remove-dashboard-items', $items(string|array), $roles(string|array));

  • remove-emoji
    intervention('remove-emoji');

  • remove-help-tabs
    intervention('remove-help-tabs');

  • remove-howdy
    intervention('remove-howdy', $replace(string));

  • remove-menu-items
    intervention('remove-menu-items', $items(string|array), $roles(string|array));

  • remove-page-components
    intervention('remove-page-components', $components(string|array));

  • remove-post-components
    intervention('remove-post-components', $components(string|array));

  • remove-taxonomies
    intervention('remove-taxonomies', $taxonomies(string|array));

  • remove-toolbar-frontend
    intervention('remove-toolbar-frontend', $roles(string|array));

  • remove-toolbar-items
    intervention('remove-toolbar-items', $items(string|array), $roles(string|array));

  • remove-update-notices
    intervention('remove-update-notices', $roles(string|array));

  • remove-user-fields
    intervention('remove-user-fields', $fields(string|array), $roles(string|array));

  • remove-user-roles
    intervention('remove-user-roles', $roles(string|array));

  • remove-widgets
    intervention('remove-widgets', $widgets(string|array));

  • update-dashboard-columns
    intervention('update-dashboard-columns', $amount(integer));

  • update-label-footer
    intervention('update-label-footer', $label(string));

  • update-label-page
    intervention('update-label-page', $labels(string|array));

  • update-label-post
    intervention('update-label-post', $labels(string|array));

  • update-pagination
    intervention('update-pagination', $amount(integer));

Updates

Composer:

  • Change the composer.json version to ^1.2.0**
  • Check CHANGELOG.md for any breaking changes before updating.
$ composer update

WordPress:

Includes support for github-updater to keep track on updates through the WordPress backend.

Other