acpt/save_meta_field
Fires after a single meta field value is saved
Type: Action
Fires after a single meta field value is saved to its location (a post, term, user, comment, option page, or WooCommerce product attribute).
Parameters
Parameter
Type
Description
$command
AbstractSaveMetaCommand
The command instance that performed the save
$fieldModel
MetaFieldModel
The field definition whose value was saved
$elementId
mixed
The ID of the location the value was saved to (post ID, term ID, user ID, etc.)
$belongsTo
string
The location type (e.g. POST_ID, TERM_ID, USER_ID)
Usage
add_action("acpt/save_meta_field", function(AbstractSaveMetaCommand $command, $fieldModel, $elementId, $belongsTo){
// do something
}, 10, 4);Last updated