### [wpforms_entry_save_args](https://wpforms.com/developers/wpforms_entry_save_args/)

**Published:** March 25, 2021
**Author:** Editorial Team

**Excerpt:** You can use the wpforms_entry_save_args filter to change the entry details that are passed through to the wpforms_entry_save_fields filter to alter any of the information captured from the form. 

**Content:**

## Description

The `wpforms_entry_save_args` filter is fired before saving the entry and will pass through the arguments for the details captured with the submission.

## Parameters

$args*(array)* Processed submission data, prepared to be stored later such as the user IP Address, user agent, date, etc.$form\_data*(array)* Processed form settings/data, prepared to be used later.## Source

`wpforms/pro/wpforms-pro.php`

## More Information

The `wpforms_entry_save_args` filter can be used to alter any information captured during the submission processing before saving the entry.

## Example

```

/**
 * Filter for arguments passed through form submission prior to saving the entry.
 *
 * @link    https://wpforms.com/developers/wpforms_entry_save_args/
 *
 * @param   array  $args       Processed submission data, prepared to be stored later.
 * @param   array  $form_data  Processed form settings/data, prepared to be used later.
 *
 * @return  array
 */

function wpf_dev_entry_save_args( $args, $form_data ) {
   
    // Only run on my form with ID = 143, remember to change this to match your form ID
    if( $form_data[ 'id' ] != 143 ) {
        return $args;
    }
   
    $args[ 'user_id' ] = '';
    $args[ 'ip_address' ] = '';
     
    return $args;
  
}
add_filter( 'wpforms_entry_save_args', 'wpf_dev_entry_save_args', 10, 2 );

```

## Related

Tutorial Reference: [How to Create an Anonymous Survey Form for Logged In Users](https://wpforms.com/developers/how-to-create-an-anonymous-survey-form-for-logged-in-users/ "How to Create an Anonymous Survey Form for Logged In Users")

**Categories:** Filters Hooks

**Tags:** PHP

---

