diff options
author | Stefan Ritter <xeno@thehappy.de> | 2009-11-02 14:14:21 +0100 |
---|---|---|
committer | Stefan Ritter <xeno@thehappy.de> | 2009-11-02 14:14:21 +0100 |
commit | bb47b2dbd9cc46476d7f4668fe34921b8f2e9afe (patch) | |
tree | 3f017b10d84c5818076c07efd2b1a4e3a26deea9 | |
parent | 2a108530e7cd079ec08762aac10675030e98231b (diff) |
Added labels for each comment
-rwxr-xr-x | blogthon.cgi | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/blogthon.cgi b/blogthon.cgi index 423ce25..d34e08b 100755 --- a/blogthon.cgi +++ b/blogthon.cgi @@ -452,6 +452,7 @@ else: print ' <div class="comments">' notfirstline = 0 # Ugly fix for closing comment containers + label_count = 0 for line in comments_content: if re.search("^-", line): @@ -460,6 +461,11 @@ else: print ' </div>' notfirstline = 0; print ' <div class="comment">' + + #Label for each comment + label_count += 1 + print ' <a name="' + str(label_count) + '"></a>' + print ' <div class="comment_author">' + line.split(".", 1)[1].strip() + '</div>' elif re.search("^\+", line): print ' <div class="comment_date">' + line.split(".", 1)[1].strip() + '</div>' |