Cartoon of Author

@zackeryfretty

Trigger Specific Feeds for Partial Entries with Gravity Forms

🗓

Gravity Forms has a nifty add-on called "Partial Entries" that'll store partially completed form submissions in the database, which can be useful for setting up abandoned cart automations and the like.

Unfortunately, by default, there's no way to trigger a specific feed to run when a partial entry is created and the example that Gravity Forms shows in their documentation will run ALL of your feeds when a partial entry is created, which isn't too helpful.

HOWEVER --

With a little tweaking to the example function they provide you can easily make this work per form / per feed, like so:

add_action( 'gform_partialentries_post_entry_saved', 'send_to_mailchimp_on_partial_entry_saved', 10, 2 );
function send_to_mailchimp_on_partial_entry_saved( $partial_entry, $form ) {
if ( function_exists( 'gf_mailchimp' ) ) {
// The ID of your Gravity Form
$form = GFAPI::get_form( 8 );
// The ID of your Feed
$feed = GFAPI::get_feed( 16 );
$partial_entry['status'] = 'partial';
gf_mailchimp()->process_feed( $feed, $partial_entry, $form );
}
}

That specific example will process the MailChimp Feed ID #16 on Gravity Form ID #8 when a partial entry is created.

You'll need to adjust it a bit for different add-ons, but that's the general gist of it.

———