function theme_guestbook_entry_comment in Guestbook 5
Same name and namespace in other branches
- 5.2 guestbook.module \theme_guestbook_entry_comment()
- 6.2 guestbook.module \theme_guestbook_entry_comment()
- 6 guestbook.module \theme_guestbook_entry_comment()
- 7.2 guestbook.module \theme_guestbook_entry_comment()
1 theme call to theme_guestbook_entry_comment()
File
- ./
guestbook.module, line 771
Code
function theme_guestbook_entry_comment($uid, $entry, $comment_entry) {
$display = (array) variable_get('guestbook_display', array(
'date',
'email',
'website',
'comments',
));
$output = '';
if ($comment_entry == $entry['id']) {
// Display comment edit form.
$output .= guestbook_form_comment($uid, $entry);
}
else {
if (in_array('comments', $display) && $entry['comment'] != '') {
// Display comment.
$commentby = user_access('access user profiles') ? l($entry['commentby'], "user/{$entry['commentauthor']}") : $entry['commentby'];
$output .= '<small>' . t('Comment by') . ' ' . $commentby . "</small><br />";
$output .= '<em>' . check_plain($entry['comment']) . '</em>';
}
}
return '<div class="guestbook-comment content">' . $output . '</div>';
}