Actions
Customize your ACPT experience by hooking into these actions.
acpt/init
Fires after ACPT is fully initialized.
Usage:
add_action("acpt/init", function(ACPT_Plugin $plugin){
// do something
});
acpt/save_form
Fires after a form is saved.
Usage:
add_action("acpt/save_form", function(HandleFormSubmissionCommand $command, FormModel $form){
// do something
}, 10, 2);
acpt/save_meta_field
Fires after a meta field is saved.
Usage:
add_action("acpt/save_meta_field", function(AbstractSaveMetaCommand, $fieldModel, $elementId, $belongsTo){
// do something
}, 10, 4);
acpt/meta_group/save
Fires after the meta group settings are saved.
Usage:
add_action("acpt/meta_group/save", function(SaveMetaGroupCommand $command, MetaGroupModel $group){
// do something
}, 10, 2);
acpt/custom_post_type/save
Fires after the custom post type settings are saved.
Usage:
add_action("acpt/custom_post_type/save", function(SaveCustomPostTypeCommand $command, CustomPostTypeModel $postModel){
// do something
}, 10, 2);
acpt/taxonomy/save
Fires after the taxonomy settings are saved.
Usage:
add_action("acpt/taxonomy/save", function(SaveTaxonomyCommand $command, TaxonomyModel $taxonomy){
// do something
}, 10, 2);
Last updated