Google automatically detects when sites are using common forum software and formats the display of the SERPs for all sites that use that forum software.
I would expect that Google would support a schema.org microdata markup for forum sites. However, there there is no microdata markup available that I could find. Here is a thread from Google product forums that indicates that the forum display in the SERPs is not part of the normal "rich snippets" enhanced display. Google must have written code to identify signatures of all common forum software. That makes it harder for custom built forums to figure out what needs to be done to get Google to recognize their forums.
The best that I can suggest would be to emulate existing forum software as best as possible:
- With each post, be sure to use the phrase "by AUTHOR".
- Use a date format that Googlebot is sure to recognize:
Mon Jan 1, 1970 12:00 pm
Use markup for each post similar to what existing forum software produces:
<div class="post"> <div class="postbody"> <h3>THIS IS THE TITLE OF THE POST</h3> <p class="author">by <a href="author.html">AUTHOR NAME</a> » DATE </p> <div class="content"> BODY OF POST </div> </div>
Use breadcrumbs with "Home", "Forum list", Topic list", "Topic items.
Here is an article that shows how RDFa might be used to mark up forum HTML to make the task of scraping this data out of forums easier for Google. Using the RDFa markup proposed might make it more likely that would identify the site as a forum. Here is a great graphic from the article showing which items would get marked up with semantic data: