Change the WordPress post updated messages

Sometimes it is necessary to modify or remove the default WordPress post updated messages that are displayed when making changes to a Post in WordPress.

One example is when you are creating a custom post type that does not have a permalink. When you save a draft, publish or update a published post, you are presented with messaging that includes a link to the post – which in that case will take the user to a 404 page.


The post_updated_messages  filter gives you access to the default WordPress post updated messages for all post types and the $messages parameter is  an associative array with with each index being the name of the post type and the corresponding values as an array.

Checkout the Codex entry for register_post_type() for more details on registering post types in general.

Hope it helps!



One Reply to “Change the WordPress post updated messages”

Comments are closed.