Require Post Category
Require users to choose a post category before saving a draft or publishing. After activation all users will be required to choose a category before saving a draft, updating a post, or publishing a post. This applies to normal posts and may not be compatible with custom write panels or custom post types.
Download
Version: 1.0.1
Release Date: 2/17/2011
Compatibility: WordPress 2.9.2 up to 3.2
Require Post Category (30.8 KiB, 22 hits)
Installation
- Extract the file to your
wp-content/pluginsdirectory - Activate the plugin



Hello,
I’ve installed this plugin recently and it works well but i found a problem with it, when i want to create or update a page i got the message showing so i must disable it when i work on a page because of course page don’t have categories…
Will it be corrected in the next version ?
You’re absolutely right, the script shouldn’t be included when adding/editing pages, I forgot that pages are just another post type. I’ll release a new version with the fix tomorrow.
1.0.1 has been released, which fixes the issue of the alert coming up when adding/editing pages.
Thanks for this plugin – it’s given me some foundation to work out my problem. Instead of the categories being checked, I wanted to do a check on the text area of a metabox. I used to .value instead of length, but seem to get an error with the click event. could you point me where I could be going wrong?
If you put your code and error up on pastebin I can take a look. Your code for checking the textarea should be similar to this:
This plugin caused problems with my “Featured Images”
When this plugin is enabled, my Featured Images no longer save, they are removed after publishing.
Not sure why?
I’ll check this out, thanks for dropping a comment.
UPDATE: I’m unable to replicate your issue. I was able to choose a featured image for a post and update the post without problem. I also created a new post, set a featured image, and saved a draft without issue. It sounds like you may be having an issue with Require Post Category conflicting with another plugin. If you find out anything more let me know. Thanks!
Hi, I update this plugin using language translation.
First, replace yout string:
alert('" . __('Oops, please select a category before publishing this post.','require-post-category') . "');Last Create this function and insert this action:
add_action( 'init', 'rpc_translation' );
function rpc_translation() {
load_plugin_textdomain('require-post-category','wp-content/plugins/require-post-category');
}
Now, insert a poedit file.
Thanks for the addition Leo! I’ll work on incorporating it when i have some time.