_forum_format

Versions
4.6 – 5
_forum_format($topic)

Formats a topic for display

@TODO Give a better description. Not sure where this function is used yet.

Code

modules/forum.module, line 669

<?php
function _forum_format($topic) {
  if ($topic && $topic->timestamp) {
    return t('%time ago<br />by %author', array('%time' => format_interval(time() - $topic->timestamp), '%author' => theme('username', $topic)));
  }
  else {
    return message_na();
  }
}
?>
Login or register to post comments
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.