How to update an an additional after frm_after_update_field

Labels

This Discussion is public

Notifications

I have an update field link that correctly updates a field. I also need to update another field in the same form (id-1580)and I have tried this code below, but it does not work.  Any help appreciated.

 

add_action('frm_after_update_field', 'frm_trigger_entry_update'); //sends an email after field is updated
function frm_trigger_entry_update($atts){
$entry = FrmEntry::getOne($atts['entry_id']);
$form = FrmForm::getOne( $entry->form_id );
if ($form == 26) FrmEntryMeta::update_entry_meta($entry, 1580, '', 'View');
FrmFormActionsController::trigger_actions('update', $form, $entry, 'email' );
}

Reply to this Discussion