Skip to content

Replace the standard post tag meta box with a category-style checklist (checkboxes).

Notifications You must be signed in to change notification settings

WebDevStudios/post-tag-checklist

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Post Tag Checklist

Replace the standard post tag meta box on the post edit screen with a category-style checklist (checkboxes). One key benefit over the standard post tag meta box is the ability to prevent users (by role, etc.) from creating new tags.

Post Tag Checklist screenshot

Requirements

PHP 5.4+

Installation

Download the zip file and install it using the WordPress plugin installer.

Usage

Once installed this plugin will automatically convert the post tag meta box to the category-style checklist. This behavior can be changed by filtering 'post_tag_checklist_toggle':

<?php
/**
 * Show standard post tag meta box to users who have the 'manage_post_tags' capability.
 *
 * @param bool   $render_checklist Whether or not to render the post tag checklist. Default is true.
 * @param array  $args             Array of arguments for the taxonomy.
 * @param string $taxonomy         Taxonomy name.
 * @return bool
 */
add_filter( 'post_tag_checklist_toggle', function( $render_checklist, $args, $taxonomy ) {
	if ( current_user_can( 'manage_post_tags' ) ) {
		return false;
	}
	
	return $render_checklist;
}, 10, 3 );

About

Replace the standard post tag meta box with a category-style checklist (checkboxes).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 100.0%