• Resolved deepgc

    (@deepgc)


    Hello,

    I am trying to develop a simple blog using the Corner Theme.

    On the main page, I wanted the full text of the posts to be made so I edited the Main Index Template with the following:

    <body> <?php the_content(); ?> </body>
    
    <?php
    wp_list_comments( array( 'type' => 'comment' ), $comments ); ?>

    However, when I add the comments, I get a reply button on the bottom which doesn’t do anything, and I could do with it being deleted if possible?

    Help!

Viewing 10 replies - 1 through 10 (of 10 total)
  • a2ztechnologies

    (@a2ztechnologies)

    Hi.,

    all code must in the body tag

    Try this

    <body>
    <?php the_content(); ?>
    <?php wp_list_comments( array( 'type' => 'comment' ), $comments ); ?>
    </body>
    Thread Starter deepgc

    (@deepgc)

    That didn’t work,

    <body>
    
    <?php the_content(); ?>
    <?php wp_list_comments( array( 'type' => 'comment'), $comments ); ?>
    
    </body>

    I need the reply button deleting, see : https://blog.mychoons.com

    a2ztechnologies

    (@a2ztechnologies)

    Hi deepgc.,

    <body>
    <?php the_content(); ?>
    <?php comments_template(); ?>
    </body>

    Try this one

    Thread Starter deepgc

    (@deepgc)

    The above doesn’t display any comments at all :/

    a2ztechnologies

    (@a2ztechnologies)

    <?php if( have_posts() ){
    	while( have_posts() ){ the_post();?>
    	<h3><?php the_title();?></h3>
    	<?php the_content();?>
    	<?php comments_template(); ?>
    	<?php }
    }?>

    Finally ??

    Thread Starter deepgc

    (@deepgc)

    ^ That seemed to put the php on a constant loop,

    It kept repeating the same post, yet at the same time the comments_template() function does not appear to do anything?

    a2ztechnologies

    (@a2ztechnologies)

    Thread Starter deepgc

    (@deepgc)

    It’s the front page I was hoping to correct, the post itself is fine. On the front page I’d like a list of posts with the content and comments, but without a reply button on the front page.

    a2ztechnologies

    (@a2ztechnologies)

    Ok use another trick

    <?php if( is_home() ){?>
    <style type="text/css">
    .comment-reply-link{ display:none; }
    </style>
    <?php }?>

    Paste on your footer.php

    if you don’t want replay link on home page

    Thread Starter deepgc

    (@deepgc)

    I think I’m just going to leave the comments off the front page. I’ve just added a new post and it’s also including the comments from the first post under the second post.

    Never mind, thanks for your help anyway ??

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘wp_list_comments’ is closed to new replies.