Matthew Park
asked 9 years ago

DW Question & Answer allows the use of WP media library when asking a question but the same function does not exist when answering the question.

I would really appreciate it if anyone has a working code that can be shared.

1 Answers
Allen
answered 9 years ago

@Matthe Park: hi, for the dw-question-answer, you can open file : dw-question-answe\inc\templates\default\answer-submit-form.php and then go to line 18, add this line to the array : 'media_buttons' => true,

It’s mean the code from line 14-->19 will be come like this :

$editor = array( 
        'wpautop'       => false,
        'id'            => 'dwqa-answer-question-editor',
        'textarea_name' => 'answer-content',
        'rows'          => 2,
        'media_buttons' => true,
    );

And this button will just appear if you login with admin account.
Hope this help.

Powered by DW Question & Answer Pro