diff options
Diffstat (limited to 'src/application/views/view_user.php')
| -rw-r--r-- | src/application/views/view_user.php | 8 | 
1 files changed, 7 insertions, 1 deletions
| diff --git a/src/application/views/view_user.php b/src/application/views/view_user.php index 536cc33..6631407 100644 --- a/src/application/views/view_user.php +++ b/src/application/views/view_user.php @@ -46,8 +46,14 @@ $dateJoined->setTime(0, 0, 0, 0);      <div class="post-container">          <div class="post-container-posts">              <div class="list-group margin-top"> -                <?php foreach ($posts as $post): if ($post->deleted) continue; ?> +                <?php foreach ($posts as $post): +                    if ($post->deleted) continue; +                    $hasAttachments = count($attachments[$post->id]) > 0; +                ?>                      <a href="?_action=viewtopic&topic=<?= htmlentities(urlencode($post->topicId)) ?>#post-<?= htmlentities(urlencode($post->id)) ?>" class="list-group-item"> +                        <?php if ($hasAttachments): ?> +                            <span class="badge"><span class="glyphicon glyphicon-paperclip"></span></span> +                        <?php endif; ?>                          <?= htmlentities(StringUtils::truncate(strip_tags(renderPost($post->content)), 100)) ?><br>                          <span class="text-muted"><?= __("posted on %post_date% in %topic%", [                              "post_date" => '<span class="_time">' . htmlentities($post->postDate->format("c")) . '</span>', |