<form
        id="fmanswer"
        action="{% url answer question.id %}"
        method="post"
        >{% csrf_token %}
    <div style="clear:both"></div>
    {% if request.user.is_anonymous() and settings.ALLOW_POSTING_BEFORE_LOGGING_IN == False %}
        {% if not thread.closed %}
            <a
                    class="button submit"
                    href="{{settings.LOGIN_URL}}?next={% url question question.id %}"
                    >{{ settings.WORDS_LOGIN_SIGNUP_TO_ANSWER|escape }}</a>
        {% endif %}
    {% else %}
        {% if not thread.closed and settings.READ_ONLY_MODE_ENABLED == False %}
            <div>
                {% spaceless %}
                    <h2>
                        {% if answers %}
                            {{ settings.WORDS_YOUR_ANSWER|escape }}
                        {% else %}
                            {{ settings.WORDS_BE_THE_FIRST_TO_ANSWER_THIS_QUESTION|escape }}
                        {% endif %}
                    </h2>
                {% endspaceless %}
            </div>
            <p class="message">
            {% if request.user.is_anonymous() %}
                {{ settings.WORDS_INSTRUCTION_TO_POST_ANONYMOUSLY }}
            {% elif request.user==question.author  %}
                {{ settings.WORDS_INSTRUCTION_TO_ANSWER_OWN_QUESTION }}
            {% endif %}
                {{ settings.WORDS_INSTRUCTION_TO_GIVE_ANSWER }}
            </p>
            <div class="folded-editor{% if editor_is_unfolded %}unfolded{% endif %}" tabindex="6">
              <p class="prompt"><a>{{ settings.WORDS_ADD_ANSWER|escape }}</a></p>
                <div class="editor-proper">
                    {{ macros.edit_post(answer) }}
                    <div class="answer-options">
                        {% if settings.WIKI_ON %}
                            {{ macros.checkbox_in_div(answer.wiki) }}
                        {% endif %}
                        {% if settings.GROUPS_ENABLED and 
                            request.user.is_authenticated() and 
                            request.user.can_make_group_private_posts()
                        %}
                            {{ macros.checkbox_in_div(answer.post_privately) }}
                        {% endif %}
                        {% set post_form=answer %}
                        {% include "widgets/proxy_author_fields.html" %}
                    </div>
                    {% if answer.recaptcha %}
                        <div>{{ macros.form_field_with_errors(answer.recaptcha) }}</div>
                        <div class="clearfix"></div>
                    {% endif %}
                    <input id="add-answer-btn" type="submit" class="submit"/>
                    <script type="text/javascript">
                        askbot['functions']['renderAddAnswerButton']();
                    </script>
                </div>
            </div>
        {% endif %}
    {% endif %}
</form>
