Limit post view and management to custom user meta information

You have to filter user_has_cap and compare the user meta fields. The following code is based on this answer and not tested. add_filter( ‘user_has_cap’, ‘wpse_99393_filter_cap’, 10, 3 ); /** * Allow editing others posts only for editors from the same school. * Administrators can still edit those posts. * * @wp-hook user_has_cap * @param array … Read more

Contributor post to be reviewed and published by only one editor

You don’t say how you save the editor -> contributor associations, I assume you store it in a user meta field with key ‘assigned_contrib’ where you save an array of contributors user id. First off all, hide posts to other editors using pre_get_posts hook: add_action(‘pre_get_posts’, ‘hide_posts_to_editors’); function hide_posts_to_editors( $query ) { if ( is_admin() && … Read more

WordPress page editor for clients, opinions needed

It is the theme author’s responsibility to give an admin interface that will allow the client to create the content in the form he wants. Layout related options and shortcodes are just a way for the author to justify doing a poor job in understanding the client’s needs and helping the client to easily manage … Read more

Directly open page in text editor

Add the following to your themes functions.php file and it will default to the editors text view… add_filter( ‘wp_default_editor’, create_function(”, ‘return “html”;’) );

How can show my images style from editor

add_editor_style allows theme developers to link a custom stylesheet file to the TinyMCE visual editor. You’ll want to duplicate many (if not all) of your styles from the front-end to be included in that file. Then editing in the visual editor will look more like your front-end css. The problem is more likely that you … Read more