February 27th, 2002

livejournal: old URL support & use anum-ified IDs in more places for consistency

Module Name: livejournal
Committed By: bradfitz
Date: Wed Feb 27 18:06:58 UTC 2002

Modified Files:
---------------
livejournal/cgi-bin: talklib.pl
livejournal/htdocs: delcomment.bml talkread.bml

Log Message:
------------
avva:

This patch does three things:
1) makes links of the form
http://www.livejournal.com/talkread.bml?itemid=1234&thread=5678

continue to work after the journal has been clusterised.

2) makes talkread.bml use ditemid-style links for "thread=" arguments,
associated #name anchor tags, and "id=" argument to delcomment.bml,
for all posts.

Just like currently with "replyto", the code uses the anum value of
the post in order to create a "dtalkid", seeing that individual
comments don't have anum's of their own (for some reason I thought
they did, but I seem to've been mistaken).

A different way to achieve consistency would be to have 'replyto' use
the real talkid instead of dtalkid. But that would mean: 1) much less
trivial changes in the code; 2) inconsistency between "public-style"
itemid's and "real-style" talkid's; 3) ability of everyone to see
immediately how many comments the user has in the journal -- which is
something we don't want to happen for events, anyway, so might as well
"hide" it here.

3) makes delcomment.bml handle the dtalkid-style of its argument.

I think I tested it pretty well.

bradfitz:

If there are bugs, they might be in my changes to the patch. :)


To generate a diff of this commit:
cvs rdiff -r1.13 -r1.14 livejournal/cgi-bin/talklib.pl
http://cvs.livejournal.org/browse.cgi/livejournal/cgi-bin/talklib.pl.diff?r1=1.13&r2=1.14
cvs rdiff -r1.12 -r1.13 livejournal/htdocs/delcomment.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/delcomment.bml.diff?r1=1.12&r2=1.13
cvs rdiff -r1.56 -r1.57 livejournal/htdocs/talkread.bml
http://cvs.livejournal.org/browse.cgi/livejournal/htdocs/talkread.bml.diff?r1=1.56&r2=1.57