id summary reporter owner description type status priority milestone component version severity resolution keywords cc focuses 7094 Filter to allow insertion of messages onto the post edit form simonwheatley westi "Currently it's not easily possible to insert a message onto the edit form; for example a plugin might check a post on publication, determine it's unsuitable in some way and need to return the user to their post with a message explaining what's happened. The attached patch adds a filter hook to allow plugin authors to manipulate the message being displayed on edit_form_advanced.php. Example plugin code shown below: {{{ // Fictional example, for simplicity... // This function triggered by a $_GET param. The $_GET // param is added if the profanity filter detects rudeness. function em_filter_display_message( $display_message ) { // Should we display a message? $em_message = (bool) @ $_GET['em_message']; if ( ! $em_message ) return $display_message; // OK. Let's display one... return 'Hello. This is WordPress speaking... less profanity in your posts, please.'; } // Our message add_filter( 'edit_form_advanced_message', 'em_filter_display_message' ); }}}" enhancement closed normal Administration normal invalid needs-patch