|
@@ 3893-3898 (lines=6) @@
|
| 3890 |
|
if ( $cat_id > 0 && $term = (array)term_exists( $cat_id, $taxonomy ) ) {
|
| 3891 |
|
$term_data['term_id'] = $term['term_id'];
|
| 3892 |
|
|
| 3893 |
|
if ( $term_id = geodir_imex_update_term( $taxonomy, $term_data ) ) {
|
| 3894 |
|
$updated++;
|
| 3895 |
|
} else {
|
| 3896 |
|
$invalid++;
|
| 3897 |
|
geodir_error_log( wp_sprintf( $gd_error_log, ($index + 1) ) . ' ' . __( 'Could not be updated due to invalid data (check & remove if any invalid characters used in data)', 'geodirectory' ) );
|
| 3898 |
|
}
|
| 3899 |
|
} else if ( $term_data['slug'] != '' && $term = (array)term_exists( $term_data['slug'], $taxonomy ) ) {
|
| 3900 |
|
$term_data['term_id'] = $term['term_id'];
|
| 3901 |
|
|
|
@@ 3902-3907 (lines=6) @@
|
| 3899 |
|
} else if ( $term_data['slug'] != '' && $term = (array)term_exists( $term_data['slug'], $taxonomy ) ) {
|
| 3900 |
|
$term_data['term_id'] = $term['term_id'];
|
| 3901 |
|
|
| 3902 |
|
if ( $term_id = geodir_imex_update_term( $taxonomy, $term_data ) ) {
|
| 3903 |
|
$updated++;
|
| 3904 |
|
} else {
|
| 3905 |
|
$invalid++;
|
| 3906 |
|
geodir_error_log( wp_sprintf( $gd_error_log, ($index + 1) ) . ' ' . __( 'Could not be updated due to invalid data (check & remove if any invalid characters used in data)', 'geodirectory' ) );
|
| 3907 |
|
}
|
| 3908 |
|
} else {
|
| 3909 |
|
if ( $term_id = geodir_imex_insert_term( $taxonomy, $term_data ) ) {
|
| 3910 |
|
$created++;
|
|
@@ 3908-3915 (lines=8) @@
|
| 3905 |
|
$invalid++;
|
| 3906 |
|
geodir_error_log( wp_sprintf( $gd_error_log, ($index + 1) ) . ' ' . __( 'Could not be updated due to invalid data (check & remove if any invalid characters used in data)', 'geodirectory' ) );
|
| 3907 |
|
}
|
| 3908 |
|
} else {
|
| 3909 |
|
if ( $term_id = geodir_imex_insert_term( $taxonomy, $term_data ) ) {
|
| 3910 |
|
$created++;
|
| 3911 |
|
} else {
|
| 3912 |
|
$invalid++;
|
| 3913 |
|
geodir_error_log( wp_sprintf( $gd_error_log, ($index + 1) ) . ' ' . __( 'Could not be added due to invalid data (check & remove if any invalid characters used in data)', 'geodirectory' ) );
|
| 3914 |
|
}
|
| 3915 |
|
}
|
| 3916 |
|
} else if ( $import_choice == 'skip' ) {
|
| 3917 |
|
if ( $cat_id > 0 && $term = (array)term_exists( $cat_id, $taxonomy ) ) {
|
| 3918 |
|
$skipped++;
|
|
@@ 3921-3928 (lines=8) @@
|
| 3918 |
|
$skipped++;
|
| 3919 |
|
} else if ( $term_data['slug'] != '' && $term = (array)term_exists( $term_data['slug'], $taxonomy ) ) {
|
| 3920 |
|
$skipped++;
|
| 3921 |
|
} else {
|
| 3922 |
|
if ( $term_id = geodir_imex_insert_term( $taxonomy, $term_data ) ) {
|
| 3923 |
|
$created++;
|
| 3924 |
|
} else {
|
| 3925 |
|
$invalid++;
|
| 3926 |
|
geodir_error_log( wp_sprintf( $gd_error_log, ($index + 1) ) . ' ' . __( 'Could not be updated due to invalid data (check & remove if any invalid characters used in data)', 'geodirectory' ) );
|
| 3927 |
|
}
|
| 3928 |
|
}
|
| 3929 |
|
} else {
|
| 3930 |
|
$invalid++;
|
| 3931 |
|
geodir_error_log( wp_sprintf( $gd_error_log, ($index + 1) ) . ' ' . __( 'Could not be added due to invalid data (check & remove if any invalid characters used in data)', 'geodirectory' ) );
|