forum-submitted.tpl.php in Drupal 7
Same filename and directory in other branches
Formats a forum post submission string.
The submission string indicates when and by whom a topic was submitted.
Available variables:
- $author: The author of the post.
- $time: How long ago the post was created.
- $topic: An object with the raw data of the post. Potentially unsafe. Be sure to clean this data before printing.
2 theme calls to forum-submitted.tpl.php
- template_preprocess_forum_list in modules/
forum/ forum.module - Preprocesses variables for forum-list.tpl.php.
- template_preprocess_forum_topic_list in modules/
forum/ forum.module - Preprocesses variables for forum-topic-list.tpl.php.
File
modules/forum/forum-submitted.tpl.phpView source
<?php
/**
* @file
* Formats a forum post submission string.
*
* The submission string indicates when and by whom a topic was submitted.
*
* Available variables:
* - $author: The author of the post.
* - $time: How long ago the post was created.
* - $topic: An object with the raw data of the post. Potentially unsafe. Be
* sure to clean this data before printing.
*
* @see template_preprocess_forum_submitted()
* @see theme_forum_submitted()
*
* @ingroup themeable
*/
if ($time) {
?>
<span class="submitted">
<?php
print t('By !author @time ago', array(
'@time' => $time,
'!author' => $author,
));
?>
</span>
<?php
}
else {
?>
<?php
print t('n/a');
}