Hi Takayuki.
Personaly I’ve tried to implement my own custom validation on text-fields but it seems like it is never called.
On this sample I’ve tested I’ve coded an extreme mode that reject every text field with an error, but nothing occured… The form is validated… :
function wpcf7_voucher_code_validation_filter($result,$tag) {
$tags = new WPCF7_Shortcode( $tags );
$result->invalidate( $tags, __( 'NOT VALID', 'mytest' ));
return $result;
}
add_filter('wpcf7_validate_text', 'wpcf7_voucher_code_validation_filter', 20, 2);
add_filter('wpcf7_validate_text*', 'wpcf7_voucher_code_validation_filter', 20, 2);
How is it possible ?
-
This reply was modified 7 years, 6 months ago by
wptechnology.