Direct linked comment to correct page on multipage threads

mpaler - February 20, 2009 - 16:45
Project:Watcher
Version:5.x-1.6
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:needs work
Description

Hi,

Love this module!

This would be a nice to have:

For nodes that have more than one page of comments, it would be great if the comment link in the notification email also contained the page the comment is on (in addition to the comment anchor link).

Thanks,
Mike

#1

solipsist - February 27, 2009 - 00:37

Good idea! I'm keeping it for version 2!

#2

solipsist - February 27, 2009 - 00:37
Status:active» postponed

#3

mpaler - March 30, 2009 - 00:55
Status:postponed» patch (to be ported)

Hi,

I've managed to get this going on my 5.x installation. Attached is a patch with my mods...

Mike

AttachmentSize
watcher-comment-page.patch 1.1 KB

#4

solipsist - March 30, 2009 - 04:55

Nice, but this will always point to the last page of comments. Someone may have replied to an earlier comment and the comment in reply may be on the first page of comments. Because of that you need to recursively back track up the tree of comments to get the ordered sequence number of the comment the notification is about and then derive its page number. Also, we need to be able to take care of reverse date order for comments (latest first).

#5

mpaler - March 30, 2009 - 22:09

Oh jeez, you're right. How selfish of me: I didn't even think of that because I'm forcing my forum to be Flat list - expanded & oldest first so new comments are always on the bottom...

I'm afraid I'm super swamped right now -- Hopefully later this week I can can give this some more thought. However, this may prove to be a much bigger problem than I bargained for.

Mike

#6

solipsist - April 3, 2009 - 05:47

I had a sense it was a tricky one, why I've delayed implementing it. If you can come up with a patch that implements this in a way that works with what I wrote above, I could add it straight away. When patching, please use the latest version from CVS rather than the releases on the project page.

#7

solipsist - May 17, 2009 - 15:00
Status:patch (to be ported)» needs work
 
 

Drupal is a registered trademark of Dries Buytaert.