[buddypress-trac] [BuddyPress] #3253: Nested activity comment reply breaks after level 2
buddypress-trac at lists.automattic.com
buddypress-trac at lists.automattic.com
Wed Jun 8 01:03:12 UTC 2011
#3253: Nested activity comment reply breaks after level 2
-----------------------+-----------------
Reporter: r-a-y | Owner:
Type: defect | Status: new
Priority: critical | Milestone: 1.3
Component: Theme | Version: 1.3
Resolution: | Keywords:
-----------------------+-----------------
Comment (by Dennissmolek):
I figured this out. The form is called from a array created with the
comment ID. Say my comment is number 23.
the first comment has the ID:acomment-comment-23 and the second comment
has acomment-reply-23. The form is called ac-form-23
The reply button creates an array with a split using the(-) and then uses
the second item which in both cases is 23. the form name is aform-23. So
it all works.
in any sub replies the replies are added up. In this case, acomment-
reply-24, than acomment-reply-25, etc. This calls a form that does not
exist. This doesnt happen when you do it in ajax because it gives the ID
:acomment-reply-23 to all the reply buttons. Once you refresh the new page
it loads it with the adding numbers.
Now two items having the same ID is bad code so I'm working on a patch,
but to see the fix just use firebug on any reply button that isnt working,
change its id to: acomment-reply- then the comment number of the main
comment.
--
Ticket URL: <https://trac.buddypress.org/ticket/3253#comment:12>
BuddyPress <http://buddypress.org/>
BuddyPress
More information about the buddypress-trac
mailing list