diff --git a/culqi-woocommerce.php b/culqi-woocommerce.php index cc55bdc..bb4fd08 100644 --- a/culqi-woocommerce.php +++ b/culqi-woocommerce.php @@ -69,12 +69,12 @@ function wc_culqi_scripts() */ function some_custom_checkout_field_process() { error_log("[CULQI]...Validando..."); - if(preg_match('/^[^0-9±!@£$%^&*_+§¡€#¢§¶•ªº«\\<>?:;|=.,]{2,50}$/', $_POST['billing_first_name'])) { + if(preg_match('/^[a-zA-ZñÑáéíóúÁÉÍÓÚäöüÄÖÜß\s\-]{2,50}$/', $_POST['billing_first_name'])) { //error_log("Nombre correcto"); } else { wc_add_notice('Por favor, ingresa un nombre válido', 'error' ); } - if(preg_match('/^[^0-9±!@£$%^&*_+§¡€#¢§¶•ªº«\\<>?:;|=.,]{2,50}$/', $_POST['billing_last_name'])) { + if(preg_match('/^[a-zA-ZñÑáéíóúÁÉÍÓÚäöüÄÖÜß\s\-]{2,50}$/', $_POST['billing_last_name'])) { //error_log("Apellido correcto"); } else { wc_add_notice('Por favor, ingresa un apellido válido.', 'error' );