Make WordPress Core

Opened 7 years ago

Last modified 5 years ago

#43015 new defect (bug)

function get_previous_comments_link not working in front page

Reported by: devlife's profile devlife Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.9.1
Component: Comments Keywords: 2nd-opinion
Focuses: Cc:


function get_previous_comments_link generate wrong url in front page, but it's ok in typical page, it's because of the permalink, wordpress hasn't full permalink in front page.

Attachments (2)

Screenshot_99.png (29.8 KB) - added by justinahinon 5 years ago.
Screenshot_100.png (26.6 KB) - added by justinahinon 5 years ago.

Download all attachments as: .zip

Change History (5)

#1 @devlife
7 years ago

  • Severity changed from normal to major

#2 @swissspidy
7 years ago

  • Focuses accessibility removed
  • Severity changed from major to normal

#3 @justinahinon
5 years ago

  • Keywords 2nd-opinion added

Hello @devlife

Thanks for your ticket. I've looked into WordPress files and the function get_previous_comments_link seems to be used only in Twenty Fifteen theme in /inc/template-tags L26

I tested with the theme with a static page as home page, and the link to previous and next comments work correctly (see attached screenshots).

However, while looking in the source, I noticed that all bundled themes before Twenty Fifteen use previous_comments_link and next_comments_link and themes after Twenty Fifteen use get_the_comments_navigation (introduced in 4.4 with Twenty Sixteen).

So, I suggest to close this ticket, and maybe introduce a new one to replace {{{ get_previous_comments_link }} by {{{ previous_comments_link }} in Twenty Fifteen.

@davidakennedy @laurelfulford , do you have any thoughts about this? I'm wondering if this is not an issue related to bundled themes component.

Note: See TracTickets for help on using tickets.