Forum Replies Created
Viewing 1 post (of 1 total)
- AuthorPosts
wp_tc_questions
ParticipantFWIW, I got the functionality I was trying to achieve, thanks.
I went with configuring the confirmation redirect in the UI
Then in functions php, went with the quform_post_validate hook, and if I want to short circuit the redirect I can return an error.
add_filter(‘quform_post_validate_1’, function (array $result, Quform_Form $form) {
//do some stuff
if(//stuff did not work) {
$result = array(
‘type’ => ‘error’,
‘error’ => array(
‘enabled’ => true,
‘title’ => ”,
‘content’ => ‘It’s Broken.’
)
);
}
return $result;
}, 10, 2);- AuthorPosts
Viewing 1 post (of 1 total)