asked 4 years ago

Hi all,
I saw that the textarea field for the content of a question is not required. How can we make it required?

1 Answers
answered 4 years ago

At the moment, the plugin does not support required for the Textarea field in question submit form. If you want to have it, you need to custom the wp-content/plugins/dw-questions-answer-pro/inc/Handle.php file, find the line 446, and add the following code:

                    if ( empty( $_POST['question-content'] ) ) {
                        dwqa_add_notice( __( 'You must enter a valid question content.', 'dwqa' ), 'error' );
                        return false;
Powered by DW Question & Answer Pro