WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am working with a paginate_comments_links() function and the thing is that I have customized it slightly (wrapped with a div), I need to check if check box "Break comments into pages..." in WP admin -> Settings -> Discussion Settings -> Other comment settings was checked. So the question is how would I grab the results? The issue is that if it is not checked paginate_comments_links() will not do anything, but my div will appear.

share|improve this question
up vote 2 down vote accepted

The check is done with get_option('page_comments').

But you could use another solution:

$prev = get_previous_comments_link();
$next = get_next_comments_link();

if ( '' !== $prev . $next )
    echo "<div>$prev $next</div>";
share|improve this answer
Awesome, get_option('page_comments') exactly what I was looking for. – Ed T. Dec 22 '12 at 19:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.