Disable description field on ask question form
How to delete / disable the description field on ask question forms. If the questions is short then it becomes redundant for user to type it twice.
I found the code snippet on deprecated.php that maybe relevant with it ap_get_ask_form_fields()
If it’s the correct code, could you tell me how to override it ?. Thanks
Question is closed for new answers.
bluebeach2010 selected answer
Yes, that was deprecated. You can check this new method: AP_Form_Hooks::question_form(). For removing description, simply unset post_content using hook.
bluebeach2010 commented on answer
I’ve put this on child’s theme function. But still didn’t work. What should I do ?
add_action( ‘question_form’, ‘remove_description_field’, 9 );
function remove_description_field(){
remove_action( ‘question_form’, array( ‘AP_Form_Hooks’, ‘post_content’ ) );
}