| @@ -12,11 +12,11 @@ | ||
| 12 | 12 | if ( ! $item_ids ) { |
| 13 | 13 | return; |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | -// Fetch 20 posts at a time rather than loading the entire table into memory | |
| 16 | +// fetch 20 posts at a time rather than loading the entire table into memory | |
| 17 | 17 | while ( $next_set = array_splice( $item_ids, 0, 20 ) ) { |
| 18 | - $forms = FrmDb::get_results( 'frm_forms', array( 'id' => $next_set ) ); | |
| 18 | + $forms = FrmDb::get_results( $wpdb->prefix . 'frm_forms', array( 'id' => $next_set ) ); | |
| 19 | 19 | |
| 20 | 20 | // Begin Loop |
| 21 | 21 | foreach ( $forms as $form ) { |
| 22 | 22 | ?> |
| @@ -33,9 +33,9 @@ | ||
| 33 | 33 | <status><?php echo FrmXMLHelper::cdata( $form->status ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?></status> |
| 34 | 34 | <parent_form_id><?php echo esc_html( $form->parent_form_id ); ?></parent_form_id> |
| 35 | 35 | <?php |
| 36 | 36 | |
| 37 | - $fields = FrmDb::get_results( 'frm_fields', array( 'form_id' => $form->id ), '*', array( 'order_by' => 'field_order' ) ); | |
| 37 | + $fields = FrmDb::get_results( $wpdb->prefix . 'frm_fields', array( 'form_id' => $form->id ), '*', array( 'order_by' => 'field_order' ) ); | |
| 38 | 38 | |
| 39 | 39 | foreach ( $fields as $field ) { |
| 40 | 40 | FrmXMLHelper::prepare_field_for_export( $field ); |
| 41 | 41 | ?> |
| @@ -55,6 +55,6 @@ | ||
| 55 | 55 | <?php } ?> |
| 56 | 56 | </form> |
| 57 | 57 | <?php |
| 58 | 58 | unset( $fields ); |
| 59 | - }//end foreach | |
| 60 | -}//end while | |
| 59 | + } | |
| 60 | +} | |