Segragating Trackbacks/Pingbacks From Comments

One of the downsides to WordPress (one of the very few) is that comments and trackbacks/pingbacks get all jumbled together. Now, you might get a theme, like K2, that does this (see Blue Star Chronicles for a good example in action.) But, you might want to use a different theme. If you get lots of trackbacks/pingbacks, it is nice to see who is leaving a regular comment.

In hunting around, I found two different ways. The first can be found here, at CRE8d Design, and is straight html in the comments.php file. At the moment, I am using this method. You can see that it does different things in different themes. For Pirates Cove, it creates a separate list on the right. For the others, it creates a list of TB/PB's, then the comments.

Another involves a plugin, and a little bit of coding, available over at Perspective from cubicle. The plugin also allows you to change the index/archive so that it will display the number of comments and TB/PB's separately, like in Moveable Type. You can see both in action at my test blog, PC Test.

For this one, as it leads you to the WordPress Wiki, down in the section "Comments.php," the best way to set this up is to put the code <h3>Trackbacks/Pingbacks</h3>
<ul> <?php listtrackpings('', '<li id="trackback-%id"><a href="%url">%origin</a> (%date)<br />%content</li>'); ?> </ul>
right after the section that states how many comments there are for the post, something like <h3 id="comments"><?php comments_number('No Responses', 'One Response', '% Responses' );?> to &#8220;<?php the_title(); ?>&#8221;</h3>
. You might have to play around a bit.

As always, back your files up prior to making changes.

And let me know if you hate the way it looks in the Pirates Cove theme.

More: Playing around with the pop up comments to get them to work the same hasn't worked as of yet. MK at Perspective from cubicle has been kind enough to take a look. A work around is simply to remove all the trackbacks/pingbacks from the popup comments. If you are using some sort of plugin or script to show them on your front page, why bother in the pop ups?

From the Trackback Separator wiki, look all the way down in the section about removing trackpings being shown in the original comments list. The first part is easy, the <?php endif; ?> goes right before <?php } // end for each comment ?>

Save $10 on purchases of $49.99 & up on our Fruit Bouquets at Promo Code: FRUIT49
If you liked my post, feel free to subscribe to my rss feeds.

Both comments and trackbacks are currently closed

Comments are closed.

Bad Behavior has blocked 12420 access attempts in the last 7 days.