Adding Recent Comments To Your WordPress Theme

July 15, 2008

By default, most WordPress themes display Recent Comments in some form or another. Unfortunately, it isn’t usually very user-friendly, so it will often get removed.   Until now, most of your other options required the use of a WordPress plugin, but today I ran across a great code snippet you can use to display recent comments in a useful format. I just tested it out on my test site and it looks good. Here is the code you will want to paste into your theme’s sidebar: <h2>Recent Comments</h2> <?php global... [Read the full story]

Add Gravatars For The Post Author in WordPress

July 14, 2008

Now that Gravatar support is part of the WordPress core adding them into your WordPress theme is easy. Adding them to your comments has been documented. How about adding them to your post titles to highlight the comment author? Within the loop? That’s fairly easy too. Here’s the code: <?php echo get_avatar( get_the_author_email(), '80' ); ?> Pretty simple, huh? get_the_author_email outputs the post author’s email and the “80” is the size of the avatar image in pixels (you can change that). How this will... [Read the full story]

Separate WordPress Comments and Trackbacks

July 14, 2008

With all the WordPress themes available to WordPress users, it always surprises me how these incredible theme authors don’t take a few extra seconds to separate their theme’s trackbacks from the comments. It doesn’t look very professional and it can make it extremely difficult to follow a conversation in the comments. Separating your trackbacks and comments requires a minimal amount of coding work to set up. First, you’ll want to make a backup of your comments.php file just in case something goes wrong. Next, follow... [Read the full story]

Separating Your Author Comments in WordPress

July 14, 2008

Have you noticed while visiting some of your favorite blogs that many author comments are styled differently to help the authors comments to stand out?   This is something that isn’t overly difficult to implement on your WordPress blog, so I decided to write a quick how-to post explaining how you can easily adjust your WordPress theme to display different styles for each author. First, you’ll need to make some adjustments to the comments.php code.   Look for something similar to the following code: <li class="<?php... [Read the full story]

Adding Comment Numbers To Your WordPress Theme

July 14, 2008

This might not be such a bad thing if you don’t get very many comments, but if your blog does get comments it is probably a good idea to show off how many comments you get by numbering them. Here are the steps you can take to easily add numbers to your WordPress theme’s comments section. First thing you will want to do is create a backup your comments.php file. Locate the comments.php file. Locate the code that starts the comment loop. It will look something like this: <?php if ( $comments ) : ?> Place this code... [Read the full story]

Page 2 of 3«123»