Daniel Ferreira
asked 10 years ago

Hello how are you?
First you congratulate the excellent plugin.
I wonder if there are possibilities to put checkbox "terms of use" to ask the question?

Thank U

1 Answers
DominicStaff
answered 10 years ago

Hi,
To resolve this issue, you can open the question-submit-form.php file in the folder path "pluginsdw-question-answerinctemplatesdefault". Find the line 82 to line 84.
Replace the following code:

<div class="form-submit">
<input type="submit" value="<?php _e( 'Ask Question', 'dwqa' ) ?>" class="dwqa-btn dwqa-btn-success btn-submit-question" />
</div>  

With new code:

<div class="form-submit">
<form method="POST" action="">  
<textarea name="terms">SOME TERMS</textarea><br />
<form method="POST" action="http://www.cs.tut.fi/cgi-bin/run/~jkorpela/echo.cgi">
 <input type="checkbox" name="checkbox" value="check"  /> I have read and agreed to these terms... blah blah </br>
 <input type="submit" name="email_submit" value="<?php _e( 'Ask Question', 'dwqa' ) ?>" class="dwqa-btn dwqa-btn-success btn-submit-question" onclick="if(!this.form.checkbox.checked){alert('You must agree to the terms first.');return false}"  />
</form>
</div> 

Hope this helps !

Powered by DW Question & Answer Pro