gform_activecampaign_note

Description

Filter the note that will be created and associated with the given contact. Supports filtering which contact and/or list the note should be associated with.

Usage

The following would apply to all forms.

add_filter( 'gform_activecampaign_note', 'your_function_name', 10, 3 );

The following would apply to a specific form.

add_filter( 'gform_activecampaign_note_FORMID', 'your_function_name', 10, 3 );

Parameters

  • $note array

    Properties that will be used to create and assign the note.

    • $contact_id int

      Contact ID to associate the note with.

    • $list_id int

      List ID to associate the note with.

    • $note string

      Actual note content. HTML will be stripped.

  • $feed array

    Current Active Campaign feed being processed.

  • $entry array

    Current entry being processed.

  • $form array

    Current form being processed.

Examples

1. Customize the note.

The following example shows how you can customize the note.

add_filter( 'gform_activecampaign_note', function( $note ) {
	$note['note'] = 'My custom note.';
	return $note;
} );

Placement

This code should be placed in the functions.php file of your active theme or a custom functions plugin.

Since

This filter was added in Gravity Forms Active Campaign 1.6.

Source Code

This filter is located in GFActiveCampaign::process_feed() in includes/class-gf-activecampaign.php.