summaryrefslogtreecommitdiff
path: root/src/application/views/view_user.php
diff options
context:
space:
mode:
authorJonas Kohl2024-09-16 19:32:09 +0200
committerJonas Kohl2024-09-16 19:32:09 +0200
commit6b7e714b59e28bc138681662006941274c3261af (patch)
treec683082c0a00681542db02d415bd45968f0a517b /src/application/views/view_user.php
parentfd3d969cf658475709db6a1e5090069cce51cbbd (diff)
A lot more stuff
Diffstat (limited to 'src/application/views/view_user.php')
-rw-r--r--src/application/views/view_user.php8
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&amp;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>',