Hook naming inconsistency, support for custom post types
-
There is a naming inconsistency with the following hooks. I suggest they all have the wp_ prefix. Also I suggest that there be specific hooks for custom post types. For example, how can I hook my function to the deletion of my custom post type?
Saving
add_action(‘save_post’, ‘custom_save_function’);Trashing
add_action(‘wp_trash_post’, ‘custom_trash_function’);Restoring
add_action(‘untrash_post’, ‘custom_restore_function’);Deleting
add_action(‘delete_post’, ‘custom_delete_function’);
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Hook naming inconsistency, support for custom post types’ is closed to new replies.