Styling WordPress 2.7 author comments

Note: this site no longer uses the native WordPress commenting functionality, so the feature described below can’t be seen here.

Styling post author or registered user comments on your WordPress 2.7 blog is much easier than it was back in ol’ 2.6. The new wp_list_comments() template tag (or comment_class() if you’re doing it the hard way) automatically includes class names like byuser and bypostauthor for easy CSS styling. Slick.

See the official 2.7 theme migration guide for more details.

Styling WordPress author comments

Update: these instructions don’t apply to WordPress 2.7+. See my newer article for more information.

Ever wonder how to apply special styles to highlight WordPress comments written by the post author or another registered user? Good advice on this point is very rare. Most recommendations are to check against either an email address or a specific user ID. Both of these options are kludges, and both are fragile.

Here’s the right way to do it: Continue reading Styling WordPress author comments