﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc
1408,comments_popup_link() returns incorrect URI when there are zero comments [patch],matthewc,markjaquith,"When popup comments are disabled, the function {{{ comments_popup_link() }}} echos the URI {{{ permalink#comments }}} even when there are no comments present. In the default template the heading with the id {{{ #comments }}} does not exist on the page until the first comment has been submitted. When there are zero comments, {{{ comments_popup_link() }}} should echo {{{ permalink#respond }}} instead.

My fix for this is as follows:

In comment-functions.php, replace line 121...

{{{
comments_link();
}}}


with the following...

{{{
if (0 == $number) {
  echo get_permalink() . '#respond';
} else {
  comments_link();
}
}}}
",defect (bug),closed,low,,General,1.5.1.1,minor,fixed,comments link bg|commit bg|has-patch,
