~widelands-dev/widelands-website/trunk

« back to all changes in this revision

Viewing changes to templates/threadedcomments/inlines/reply_to.js

  • Committer: franku
  • Date: 2016-05-15 14:41:54 UTC
  • mto: This revision was merged to the branch mainline in revision 409.
  • Revision ID: somal@arcor.de-20160515144154-00m3tiibyxm0nw2w
added the old threadedcomments app as wildelands app

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
{% comment %}
2
2
    vim:ft=htmldjango:
3
3
{% endcomment %}
4
 
{% load threadedcomments_tags %}
 
4
{% load threadedcommentstags %}
5
5
{% load wlprofile_extras %}
6
6
 
7
7
<script type="text/javascript">
8
8
function show_reply_form(comment_id, url, depth) {
9
9
        var comment = $('#' + comment_id);
10
 
        var reply_link = $('#' + comment_id + " .reply_link");
 
10
        var reply_link = $('#' + comment_id + ' .reply_link');
11
11
        var reply_form = $('<div class="comment odd response" style="margin-left: ' + (depth+1) +'cm;">'
12
12
                        + '<table>'
13
13
                                + '<tr>'
14
14
                                        + '<td class="author">'
15
15
                {% if post.user.wlprofile.avatar %}
16
 
                                                + '<a href="{% url profile_view user %}">'
 
16
                                                + '<a href="{% url 'profile_view' user %}">'
17
17
                                                        + '<img style="width: 50px; height: 50px;" src="{{ user.wlprofile.avatar.url }}" />'
18
18
                                                + '</a>'
19
19
                {% endif %}
23
23
                                        + '<td class="text">'
24
24
                                                + '<form method="POST" action="' + url + '?next={{object.get_absolute_url}}">'
25
25
                                                        + '<span class="errormessage">{{ form.comment.errors }}</span>'
26
 
                                                        + '{{ form.comment }}'
 
26
                                                        /* NOCOMM franku: i don't know the reason why this do not work anymore
 
27
                                                           I just replaced it with the next line
 
28
                                                        + '{{ form.comment }}'*/
 
29
                                                        + '<textarea cols="40" id="id_comment" maxlength="1000" name="comment" rows="10"></textarea>'
27
30
                                                        + '<br />'
28
31
                                                        + '<input type="hidden" name="markup" value="1" />'
29
32
                                                        + '<input type="submit" value="Submit Comment" />'