I'm building an Advanced Forum theme and overriding some of the templates from the Naked theme.

The header of advanced-forum.naked.post.tpl.php says:

All variables available in node.tpl.php and comment.tpl.php for your theme
are available here. In addition, Advanced Forum makes available the following
variables:
- $top_post: TRUE if we are formatting the main post (ie, not a comment)
* - $reply_link: Text link / button to reply to topic.
* - $total_posts: Number of posts in topic (not counting first post).
* - $new_posts: Number of new posts in topic, and link to first new.
* - $links_array: Unformatted array of links.
* - $account: User object of the post author.
* - $name: User name of post author.
* - $author_pane: Entire contents of the Author Pane template.

However, $total_posts and $new_posts are both undefined.

Is this an error in the comment, or is there another way to get at these variables?

Thanks,

Frederik

Comments

troky’s picture

Those variables are used in advanced-forum.naked.topic-header.tpl.php template as $total_posts_count and $new_posts_count.

There is also $comment_count variable set for advanced-forum.naked.post.tpl.php