Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
857 views
in Q2A Core by
Hello, I want to hide the answer form until the button is pressed. How can I do that?
Q2A version: 1.8.1

2 Answers

+2 votes
by

Hello trundd,

You can head over to 'Admin' > 'Viewing', look for the setting 'Show answer form immediately:' and then select 'Never' in the drop-down list next to it.

Have a nice day!

by
Is it the theme you're referring to?
https://github.com/rahularyan/dude-theme
by
Yes, i am using this theme
by
Unfortunately, it doesn't work out of the box but, after skimming through the code, I found some files you might look at:

1- The 'onclick' attribute is removed here:
https://github.com/rahularyan/dude-theme/blob/e49480ee38c703df35f41e314e441d4fa5028a71/qa-theme/dude/question-q.php#L83
That's for showing/hiding the form (at least in a clean Q2A installation) in the front end.

2- The form container that needs to be shown/hidden is rendered here:
https://github.com/rahularyan/dude-theme/blob/e49480ee38c703df35f41e314e441d4fa5028a71/qa-theme/dude/answer_form.php#L13
In a clean Q2A installation, a 'style="display: none"' would be added here. It hides the form until users click on the 'Answer' button.

It'd be nice if somebody else, who also uses this theme, could step in and give you a hand.
by
Yeah, it would be really good. I can hide the box but I have no idea how to activate it again
0 votes
by
I tried these steps for this problem; I gave "visibility:hidden" to the answer form, clicking the button specified in the javascript file "visibiliyt:visible;" I changed it to, but I can't find the "answer" button. The $form $columns was created in the form of. How can I fix this?

Welcome to the Q&A site for Question2Answer.

If you have a question about Q2A, please ask here, in English.

To report a bug, please create a new issue on Github or ask a question here with the bug tag.

If you just want to try Q2A, please use the demo site.

Categories

...