Forums

wp-comments-popup help needed (7 posts)

  1. podz
    Support Maven
    Posted 5 years ago #

    What happens if you alter the code from this:
    <?php comment_text() ?>
    Posted by <?php comment_author_link() ?>
    to this:
    <?php comment_text() ?> Posted by <?php comment_author_link() ?>
    ?

  2. davidchait
    Member
    Posted 5 years ago #

    That was what I was going to ask... ;)
    It could be a natural carriage-return in the 'html' side of the output.
    Otherwise, it could be a css/formatting thing between paragraphs (default [p] formatting...).
    -d
    www.chait.net

  3. Daisyhead
    Member
    Posted 5 years ago #

    Going to give that a try right now!

  4. Daisyhead
    Member
    Posted 5 years ago #

    What file formats the output of the "comments-popup" template? There must be paragraph tags there that are formatting the output.

  5. Daisyhead
    Member
    Posted 5 years ago #

    Anyone else have any idea on how to fix this issue??

  6. tcervo
    Member
    Posted 5 years ago #

    Daisyhead,
    This will work:
    In wp-comments-popup:
    <?php if ($comments) { ?>
    <?php foreach ($comments as $comment) { ?>
    <ol id="comments">
    <li id="comment-<?php comment_ID() ?>">
    <?php comment_text() ?>
    Posted by <?php comment_author_link() ?> on <?php comment_date() ?> @ <?php comment_time() ?>

  7. <?php } // end for each comment ?>
    <?php } else { // this is displayed if there are no comments so far ?>
    No comments yet.
    <?php } ?>
    In your style sheet, add:
    div.logbody p {margin-bottom: 0.5em; margin-top: 0.5em;}
    ol#comments li { margin-bottom: 1.5em; }
    If you don't want the comment numbers, add list-style: none; to the ol#comments li definition. Plus, you can experiment with the top and bottom margins to get them how you want...
    -Tony

  • Daisyhead
    Member
    Posted 5 years ago #

    Thank you! That worked perfectly.

  • Topic Closed

    This topic has been closed to new replies.

    About this Topic

    Tags

    No tags yet.