How to style the comment list? (3 posts)

  1. Van Hooreweder
    Posted 3 years ago #

    In comments.php page there is only next for the comment list:

    <ol class="commentlist">
    	<?php wp_list_comments(); ?>

    How do I style this? Can anyone give me the link to the docs? I don't find them. Thanks.

  2. Jose Castaneda
    Posted 3 years ago #

    How I learned was looking at the way the default twenty twelve does it. It uses a callback to a function.
    <?php wp_list_comments( array( 'callback' => 'custom_comments' ) ); ?>
    Where 'custom_comments' is the name of your function for styling.

    function custom_comments( $comment, $args, $depth ){
      // The code for your custom comment styling

    Hope that helps. :)

  3. Michael
    Forum Moderator
    Posted 3 years ago #


    use a browser inspection tool (such as Firebug) to investigate the html and css structure of the comment list output in the browser, and use css to format it.

Topic Closed

This topic has been closed to new replies.

About this Topic