| @@ -16,8 +16,9 @@ | ||
| 16 | 16 | */ |
| 17 | 17 | do_action( 'frm_xml_export_before_types_loop' ); |
| 18 | 18 | |
| 19 | 19 | foreach ( $type as $tb_type ) { |
| 20 | + | |
| 20 | 21 | if ( ! isset( $tables[ $tb_type ] ) ) { |
| 21 | 22 | do_action( 'frm_xml_import_' . $tb_type, $args ); |
| 22 | 23 | continue; |
| 23 | 24 | } |
| @@ -29,17 +30,17 @@ | ||
| 29 | 30 | |
| 30 | 31 | $item_ids = $records[ $tb_type ]; |
| 31 | 32 | |
| 32 | 33 | if ( in_array( $tb_type, array( 'styles', 'actions' ), true ) ) { |
| 33 | - include __DIR__ . '/posts_xml.php'; | |
| 34 | - } elseif ( file_exists( __DIR__ . '/' . $tb_type . '_xml.php' ) ) { | |
| 35 | - include __DIR__ . '/' . $tb_type . '_xml.php'; | |
| 34 | + include dirname( __FILE__ ) . '/posts_xml.php'; | |
| 35 | + } elseif ( file_exists( dirname( __FILE__ ) . '/' . $tb_type . '_xml.php' ) ) { | |
| 36 | + include dirname( __FILE__ ) . '/' . $tb_type . '_xml.php'; | |
| 36 | 37 | } elseif ( FrmAppHelper::pro_is_installed() && file_exists( FrmProAppHelper::plugin_path() . '/classes/views/xml/' . $tb_type . '_xml.php' ) ) { |
| 37 | 38 | include FrmProAppHelper::plugin_path() . '/classes/views/xml/' . $tb_type . '_xml.php'; |
| 38 | 39 | } |
| 39 | 40 | |
| 40 | 41 | unset( $item_ids, $records[ $tb_type ], $tb_type ); |
| 41 | -}//end foreach | |
| 42 | +} | |
| 42 | 43 | |
| 43 | 44 | /** |
| 44 | 45 | * @since 5.3 |
| 45 | 46 | */ |