wordpress/wp-content/themes/basic/themify/themify-builder/classes/class-themify-builder-import-export.php
/**
	 * Prepare Builder data for export
	 *
	 * @access public
	 */
Prepare Builder data for export
@access public
Prepare Builder data for export @access public
public static function prepare_builder_data($builder_data){
		if (!empty($builder_data) && is_array($builder_data)) {
			foreach ($builder_data as &$row) {
				if (isset($row['styling']) && !empty($row['styling']['background_slider'])) {
					$row['styling']['background_slider'] = self::replace_with_image_path($row['styling']['background_slider']);
				}
				if (!empty($row['cols'])) {
					foreach ($row['cols'] as &$col) {
						if (isset($col['styling']) && !empty($col['styling']['background_slider'])) {
							$col['styling']['background_slider'] = self::replace_with_image_path($col['styling']['background_slider']);
						}
						if (!empty($col['modules'])) {
							foreach ($col['modules'] as &$mod) {
								if (isset($mod['mod_name']) && $mod['mod_name'] === 'gallery' && !empty($mod['mod_settings']['shortcode_gallery'])) {
									$mod['mod_settings']['shortcode_gallery'] = self::replace_with_image_path($mod['mod_settings']['shortcode_gallery']);
								}
								if (!empty($mod['cols'])) {
									foreach ($mod['cols'] as &$sub_col) {
										if (isset($sub_col['styling']) && !empty($sub_col['styling']['background_slider'])) {
											$sub_col['styling']['background_slider'] = self::replace_with_image_path($sub_col['styling']['background_slider']);
										}
										if (!empty($sub_col['modules'])) {
											foreach ($sub_col['modules'] as &$sub_module) {
												if (isset($sub_module['mod_name']) && $sub_module['mod_name'] === 'gallery' && !empty($sub_module['mod_settings']['shortcode_gallery'])) {
													$sub_module['mod_settings']['shortcode_gallery'] = self::replace_with_image_path($sub_module['mod_settings']['shortcode_gallery']);
												}
											}
										}
									}
								}
							}
						}
					}
				}
			}
		}
		return $builder_data;
	}
public static function prepare_builder_data ( $ builder_data ) { if ( ! empty ( $ builder_data ) && is_array ( $ builder_data ) ) { foreach ( $ builder_data as & $ row ) { if ( isset ( $ row [ 'styling' ] ) && ! empty ( $ row [ 'styling' ] [ 'background_slider' ] ) ) { $ row [ 'styling' ] [ 'background_slider' ] = self :: replace_with_image_path ( $ row [ 'styling' ] [ 'background_slider' ] ) ; } if ( ! empty ( $ row [ 'cols' ] ) ) { foreach ( $ row [ 'cols' ] as & $ col ) { if ( isset ( $ col [ 'styling' ] ) && ! empty ( $ col [ 'styling' ] [ 'background_slider' ] ) ) { $ col [ 'styling' ] [ 'background_slider' ] = self :: replace_with_image_path ( $ col [ 'styling' ] [ 'background_slider' ] ) ; } if ( ! empty ( $ col [ 'modules' ] ) ) { foreach ( $ col [ 'modules' ] as & $ mod ) { if ( isset ( $ mod [ 'mod_name' ] ) && $ mod [ 'mod_name' ] === 'gallery' && ! empty ( $ mod [ 'mod_settings' ] [ 'shortcode_gallery' ] ) ) { $ mod [ 'mod_settings' ] [ 'shortcode_gallery' ] = self :: replace_with_image_path ( $ mod [ 'mod_settings' ] [ 'shortcode_gallery' ] ) ; } if ( ! empty ( $ mod [ 'cols' ] ) ) { foreach ( $ mod [ 'cols' ] as & $ sub_col ) { if ( isset ( $ sub_col [ 'styling' ] ) && ! empty ( $ sub_col [ 'styling' ] [ 'background_slider' ] ) ) { $ sub_col [ 'styling' ] [ 'background_slider' ] = self :: replace_with_image_path ( $ sub_col [ 'styling' ] [ 'background_slider' ] ) ; } if ( ! empty ( $ sub_col [ 'modules' ] ) ) { foreach ( $ sub_col [ 'modules' ] as & $ sub_module ) { if ( isset ( $ sub_module [ 'mod_name' ] ) && $ sub_module [ 'mod_name' ] === 'gallery' && ! empty ( $ sub_module [ 'mod_settings' ] [ 'shortcode_gallery' ] ) ) { $ sub_module [ 'mod_settings' ] [ 'shortcode_gallery' ] = self :: replace_with_image_path ( $ sub_module [ 'mod_settings' ] [ 'shortcode_gallery' ] ) ; } } } } } } } } } } } return $ builder_data ; }
Prepare Builder data for export
 @access public
Prepare Builder data for export @access public
// Check for Sub-rows