Chris Tattum

Code & Design

How to hide Gravity Forms default validation message

Code, WordPress / By Chris Tattum / November 8, 2017

By default, Gravity Forms echos out the following whenever there’s a validation error:-

There was a problem with your submission. Errors have been highlighted below.

If you need to suppress this, then just add the following code to your functions.php file:-

add_filter( 'gform_validation_message', 'prefix_gf_empty_validation_message', 10, 2 );
function prefix_gf_empty_validation_message( $message, $form ) {
	return "";
}

That’s it!

Leave the first comment