• Resolved apietraszek

    (@apietraszek)


    Hello.

    Firstly. I thing that Forminator is grat. 5 stars.

    I want to change the message:
    “At least one field must be filled out to submit the form.”
    in a way, so it can appear in a different language.

    To be more specific, I want to emphasize, that my website is not multilingual. I just want to edit this message and replace it with my string. Is this possible?

    Thank You in advance.
    BR.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Dmytro – WPMU DEV Support

    (@wpmudevsupport16)

    Hello @apietraszek,

    I hope you’re doing great today!

    You can change this message by adding the following PHP snippet as a must use plugin:

    <?php
    
    add_filter( 'forminator_form_submit_response', 'wpmudev_change_empty_error_message', 9999, 2 );
    add_filter( 'forminator_form_ajax_submit_response', 'wpmudev_change_empty_error_message', 9999, 2 );
    function wpmudev_change_empty_error_message( $response, $form_id ) {
    	if ( ! empty( $response['message'] ) ) {
    		if ( $response['message'] == 'At least one field must be filled out to submit the form.' ) {
    			$response['message'] = 'Your error message.';
    		}
    	}
    
    	return $response;
    }

    – paste the code in your text editor, and replace 'Your error message.' text with your custom text (in single quotes).

    Save it as a PHP file, for instance forminator-custom-error-message.php, and upload it to /wp-content/mu-plugins/ directory on the server, which applies is as a must use plugin.

    That’s it. Please let us know if you have any questions.

    Best Regards,
    Dmytro

    Plugin Support Laura – WPMU DEV Support

    (@wpmudevsupport3)

    Hi @apietraszek ,

    We haven’t heard from you in a while, I’ll go and mark this thread as resolved. Note that you can still reply on this topic.

    If you have any additional questions or require further help, please let us know!

    Best regards,
    Laura

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.