FIX: Not working as espected with UTF8 characters

This commit is contained in:
savvasha
2021-12-14 20:06:12 +02:00
parent 9974ed6518
commit 991d8a5a23

View File

@@ -55,8 +55,8 @@ if ( class_exists( 'WP_Importer' ) ) {
// Get event format, league, and season from post vars
$event_format = ( empty( $_POST['sp_format'] ) ? false : sanitize_key( $_POST['sp_format'] ) );
$league = ( sp_array_value( $_POST, 'sp_league', '-1' ) == '-1' ? false : sanitize_key( $_POST['sp_league'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput
$season = ( sp_array_value( $_POST, 'sp_season', '-1' ) == '-1' ? false : sanitize_key( $_POST['sp_season'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput
$league = ( sp_array_value( $_POST, 'sp_league', '-1' ) == '-1' ? false : $_POST['sp_league'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput
$season = ( sp_array_value( $_POST, 'sp_season', '-1' ) == '-1' ? false : $_POST['sp_season'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput
$date_format = ( empty( $_POST['sp_date_format'] ) ? 'yyyy/mm/dd' : sanitize_text_field( wp_unslash( $_POST['sp_date_format'] ) ) );
foreach ( $rows as $row ) :