How to highlight first post in bbPress

bbPress 1.0 made it super easy to highlight or style the first post of a topic by adding a DIV ID to it. Now bbPress will automatically wrap the post in a DIV names as per its position in the topic (<div id=”position-X”>).

Now if we want to style the first post differently we would just add CSS to our theme stylesheet like :

#position-1 .threadpost { background: #c0c0c0; }

This comes as a advantage for those who are using bbPress as a discussion board where first post is a question & all others are replies. Its better to style such a post differently to make it stand out of all the posts. Have your say in the comments.

If you want more of bbPress tips & tricks, then don’t forget to check out all bbPress related articles & subscribe so you don’t miss new ones. Also I have my first bbPress plugin coming and you can hire me for bbPress related works (be it integration, custom theme, issues or custom plugins). For all the services I offer, visit my services page.