0
Welcome Guest! Login
0 items Join Now

Gruge Pingback Formatting

    • Luther's Avatar
    • Luther
    • Newbie
    • Posts: 8
    • Thanks: 0

    Gruge Pingback Formatting

    Posted 12 years 11 months ago
    • I noticed that the Grunge template doesn't include formatting specific to pingback comments. As a result, a pingback comment left on a post will look quite large and cluttered due to it being formatted as a regular comment. So, I edited rt_grunge_wp/html/layouts/comment_basic.php to include pingback specific formatting.

      Just below:
      <div class="comment-author vcard" style="line-height: 50px;">

      I added this:
      <?php $ispingb = false; if($comment->comment_type == 'pingback') { $ispingb = true; } ?>
      <?php if($ispingb) { echo '<div class="pbcomment">'; printf(_r('<cite class="fn">%s</cite>'), get_comment_author_link()); printf(edit_comment_link(_r('(Edit)'))); echo '</div></div>';} else { ?>

      And just above
      <?php echo ob_get_clean(); return;

      I added this:
      <? php } ?>

      I'm sure there is a better and more efficient way to do it, but this is how I figured it out using my limited PHP knowledge. Then I used CSS to style the pingback to my desire using .pbcomment. Just thought I would post this in case anyone else was trying to figure it out.

Time to create page: 0.047 seconds