Make WordPress Core

Opened 17 years ago

Closed 17 years ago

Last modified 11 years ago

#8811 closed defect (bug) (worksforme)

Comment custom callback and comment form placement

Reported by: jeremyclark13's profile jeremyclark13 Owned by:
Milestone: Priority: low
Severity: normal Version: 2.7
Component: Comments Keywords: custom callback comment form
Focuses: Cc:

Description

When using a custom callback the reply link places the comment form underneath any children comments, but when not using a custom callback the form is placed directly underneath the comment being replied to. You can see the difference with these two links.

With Callback
Without Callback

Change History (5)

#1 follow-up: @mrmist
17 years ago

Your no-callback page does not have the anchors in the source. So that's the reason for the box being at the end. Whether that is a bug or something you have to output yourself I am not sure at this stage.

#2 @mrmist
17 years ago

  • Milestone set to 2.8
  • Version set to 2.7

#3 in reply to: ↑ 1 @jeremyclark13
17 years ago

Replying to mrmist:

Your no-callback page does not have the anchors in the source. So that's the reason for the box being at the end. Whether that is a bug or something you have to output yourself I am not sure at this stage.

It's not the anchors I have the anchors on my blog and it still didn't work, but nevertheless I think I found the problem and It does seem to be a bug.
This is part of the link that output by the reply_link function on the callback page
onclick='return addComment.moveForm("comment-15", "15", "respond", "1")
But on the noncallback page it looks like this.
onclick='return addComment.moveForm("div-comment-17", "17", "respond", "1")
So for some reason the javascript is different between the two.

#4 @DD32
17 years ago

  • Resolution set to worksforme
  • Status changed from new to closed

Your example works for me, When using the custom callbacks, you need to ensure that the ID's of the elements are the same as those in the default theme (Which the threading commenting script is designed to pick up)

It looks like you've corrected the div id's in the 2nd page now?

The first param of the JS call is the ID of the element that it should be moved to, You can change the prefix of it via the 'add_below' param (in $args) to the comment_reply_link() function

#5 @DrewAPicture
11 years ago

  • Milestone 2.8 deleted
Note: See TracTickets for help on using tickets.