Make WordPress Core

Opened 17 years ago

Closed 17 years ago

#5448 closed defect (bug) (fixed)

Comments-template echoes strange comment link

Reported by: reinkim's profile reinkim Owned by: westi's profile westi
Milestone: 2.5 Priority: normal
Severity: normal Version: 2.5
Component: Template Keywords: has-patch tested regression
Focuses: Cc:

Description

After applying changeset [6368] comments_popup_link function in wp-includes/comments-template.php behalves differently from previous versions.

In [6368] comments_popup_link assembles $comments_popup_link variable, but in some execution path there are codes which echo the output, which should be appended to $comments_popup_link variable.

Problematic codes (all source lines from wp-includes/comments-template)

  • function comments_number echoes its result
  • function comments_link echoes its output

I made fix to the source (attached diff. file) which may need some tests.

Attachments (1)

diff.txt (1.1 KB) - added by reinkim 17 years ago.
source diff

Download all attachments as: .zip

Change History (5)

@reinkim
17 years ago

source diff

#1 @pishmishy
17 years ago

  • Keywords has-patch tested added
  • Milestone changed from 2.4 to 2.3.2
  • Version changed from 2.4 to 2.3.1

Confirmed. Tested patch, fixes issue. Needs to go into next release.

#2 @westi
17 years ago

  • Keywords regression added
  • Milestone changed from 2.3.2 to 2.4
  • Owner changed from anonymous to westi
  • Status changed from new to assigned
  • Version changed from 2.3.1 to 2.4

#3 @ryan
17 years ago

comments_number() can't be changed to always return since that could break some templates. We could hijack $deprecated and turn it into an $echo boolean, however.

#4 @matt
17 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [6372]) Revert [6368]. Fixes #5448, fixes #5247 by adding a new filter to hook in specifically to add attributes, rather than filtering the whole thing. Minor formatting cleanup of comments_popup_link.

Note: See TracTickets for help on using tickets.