WordPress.org

Ready to get started?Download WordPress

Forums

comments list (5 posts)

  1. oritzio
    Member
    Posted 1 year ago #

    I'm using this code to put the comments in my homepage:

    <?php comment_form(); ?> 
    
    <ol class="commentlist">
    	<?php
    		//Gather comments for a specific page/post
    		$comments = get_comments(array(
    			'post_id' => XXX,
    			'status' => 'approve' //Change this to the type of comments to be displayed
    		));
    
    		//Display the list of comments
    		wp_list_comments(array(
    			'per_page' => 6, //Allow comment pagination
    			'reverse_top_level' => false //Show the latest comments at the top of the list
    		), $comments);
    	?>
    </ol>

    now that gives me that which it's perfect:
    http://letshoe.com/comm1.jpg

    but after I'm writing a comment I'm getting this:
    http://letshoe.com/comm2.jpg

    So i guess it relating it to a specific post from NOV16
    how can i make that all the time I'll see all the posts?

  2. Andrew
    Forum Moderator
    Posted 1 year ago #

    Which theme are you using?

  3. oritzio
    Member
    Posted 1 year ago #

    i design it from blank... any suggestion?

  4. Marvel Labs
    Member
    Posted 1 year ago #

    Kindly insert the comment code in single.php as well so that you can see it for single posts.

  5. oritzio
    Member
    Posted 1 year ago #

    I did already,
    I copied the index.php to single.php but after i'm writing a comment and clicking on the submit it showing just this post:

    http://letshoe.com/comm2.jpg

    and i want it to show all my posts like at the homepage.
    ..?

Topic Closed

This topic has been closed to new replies.

About this Topic