Advertisement
verygoodplugins

Untitled

Apr 1st, 2020
256
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.42 KB | None | 0 0
  1. function wpf_batch_gforms_init() {
  2.  
  3.     $entry_ids = array();
  4.  
  5.     $feeds = GFAPI::get_feeds( null, null, 'wpfgforms' );
  6.  
  7.     if ( empty( $feeds ) ) {
  8.         return $entry_ids;
  9.     }
  10.  
  11.     $form_ids = array();
  12.  
  13.     foreach ( $feeds as $feed ) {
  14.         $form_ids[] = $feed['form_id'];
  15.     }
  16.  
  17.     $entry_ids = GFAPI::get_entry_ids( $form_ids );
  18.  
  19.     return $entry_ids;
  20.  
  21. }
  22.  
  23. add_filter( 'wpf_batch_gravity_forms_init', 'wpf_batch_gforms_init', 20 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement