Show More
@@ -160,4 +160,15 b' a {' | |||
|
160 | 160 | } |
|
161 | 161 | .post blockquote > blockquote { |
|
162 | 162 | padding-top: .1em; |
|
163 | } No newline at end of file | |
|
163 | } | |
|
164 | ||
|
165 | .post > .image { | |
|
166 | float: left; | |
|
167 | margin-right: 1ex; | |
|
168 | } | |
|
169 | .post > .metadata { | |
|
170 | clear: left; | |
|
171 | } | |
|
172 | .post { | |
|
173 | clear: left; | |
|
174 | } |
@@ -1,3 +1,4 b'' | |||
|
1 | from django.core.urlresolvers import reverse | |
|
1 | 2 | from django.template import RequestContext |
|
2 | 3 | from boards import forms |
|
3 | 4 | import boards |
@@ -49,7 +50,9 b' def new_post(request, thread_id=boards.m' | |||
|
49 | 50 | ip = request.META['REMOTE_ADDR'] |
|
50 | 51 | |
|
51 | 52 | tags = [] |
|
52 | if thread_id == boards.models.NO_PARENT: | |
|
53 | ||
|
54 | new_thread = thread_id == boards.models.NO_PARENT | |
|
55 | if new_thread: | |
|
53 | 56 | tag_strings = data['tags'] |
|
54 | 57 | |
|
55 | 58 | if tag_strings: |
@@ -67,9 +70,14 b' def new_post(request, thread_id=boards.m' | |||
|
67 | 70 | parent_id=thread_id, image=image, |
|
68 | 71 | tags=tags) |
|
69 | 72 | |
|
70 |
thread_to_show = (post.id if thread |
|
|
71 | thread_id) | |
|
72 | return redirect(thread, post_id=thread_to_show) | |
|
73 | thread_to_show = (post.id if new_thread else thread_id) | |
|
74 | ||
|
75 | if new_thread: | |
|
76 | return redirect(thread, post_id=thread_to_show) | |
|
77 | else: | |
|
78 | return redirect(reverse(thread, | |
|
79 | kwargs={'post_id': thread_to_show}) + '#' | |
|
80 | + str(post.id)) | |
|
73 | 81 | |
|
74 | 82 | |
|
75 | 83 | def tag(request, tag_name): |
@@ -14,13 +14,13 b'' | |||
|
14 | 14 | <a name="{{ post.id }}"></a> |
|
15 | 15 | <div class="post"> |
|
16 | 16 | {% if post.image %} |
|
17 |
<div class=" |
|
|
17 | <div class="image"> | |
|
18 | 18 | <a href="{{ post.image.url }}"><img |
|
19 | 19 | src="{{ post.image.url_200x150 }}" /> |
|
20 | 20 | </a> |
|
21 | 21 | </div> |
|
22 | 22 | {% endif %} |
|
23 |
<div class=" |
|
|
23 | <div class="message"> | |
|
24 | 24 | <span class="title">{{ post.title }}</span> |
|
25 | 25 | <a class="post_id" href="#{{ post.id }}"> |
|
26 | 26 | (#{{ post.id }})</a> |
General Comments 0
You need to be logged in to leave comments.
Login now