summaryrefslogtreecommitdiff
path: root/src/application/views/view_topic_start.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/application/views/view_topic_start.php')
-rw-r--r--src/application/views/view_topic_start.php43
1 files changed, 19 insertions, 24 deletions
diff --git a/src/application/views/view_topic_start.php b/src/application/views/view_topic_start.php
index fc54623..35befc7 100644
--- a/src/application/views/view_topic_start.php
+++ b/src/application/views/view_topic_start.php
@@ -16,17 +16,15 @@ $canDelete = ($GLOBALS["currentUser"]?->id === $topicAuthor->id && $topicAuthor-
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
- <h4 class="modal-title">Edit post</h4>
+ <h4 class="modal-title"><?= __("Edit post") ?></h4>
</div>
<div class="modal-body">
- <div class="form-group">
- <label class="sr-only" for="i_edit_message">Message:</label>
- <textarea class="form-control" name="message" id="i_edit_message" rows="12" style="resize: vertical; max-height: 500px"></textarea>
- </div>
+ <label class="sr-only" for="i_edit_message"><?= __("Message:") ?></label>
+ <textarea class="form-control" name="message" id="i_edit_message" rows="12" style="resize: vertical; max-height: 500px"></textarea>
</div>
<div class="modal-footer">
- <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove" aria-hidden="true"></span> Cancel</button>
- <button type="submit" class="btn btn-success"><span class="glyphicon glyphicon-floppy-disk" aria-hidden="true"></span> Save changes</button>
+ <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove" aria-hidden="true"></span> <?= __("Cancel") ?></button>
+ <button type="submit" class="btn btn-success"><span class="glyphicon glyphicon-floppy-disk" aria-hidden="true"></span> <?= __("Save changes") ?></button>
</div>
</div>
</form>
@@ -37,14 +35,14 @@ $canDelete = ($GLOBALS["currentUser"]?->id === $topicAuthor->id && $topicAuthor-
<div class="modal-dialog modal-danger" role="document">
<div class="modal-content panel-danger">
<div class="modal-header panel-heading">
- <h4 class="modal-title"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> Permission denied</h4>
+ <h4 class="modal-title"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> <?= __("Permission denied") ?></h4>
</div>
<div class="modal-body">
- You must be logged in to view attachments
+ <?= __("You must be logged in to view attachments") ?>
</div>
<div class="modal-footer">
- <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove" aria-hidden="true"></span> Close</button>
- <a href="?_action=auth&amp;next=<?= htmlentities(urlencode($_SERVER["REQUEST_URI"])) ?>" class="btn btn-success"><span class="glyphicon glyphicon-user" aria-hidden="true"></span> Log in</a>
+ <button type="button" class="btn btn-default" data-dismiss="modal"><span class="glyphicon glyphicon-remove" aria-hidden="true"></span> <?= __("Close") ?></button>
+ <a href="?_action=auth&amp;next=<?= htmlentities(urlencode($_SERVER["REQUEST_URI"])) ?>" class="btn btn-success"><span class="glyphicon glyphicon-user" aria-hidden="true"></span> <?= __("Log in") ?></a>
</div>
</div>
</div>
@@ -65,37 +63,34 @@ $canDelete = ($GLOBALS["currentUser"]?->id === $topicAuthor->id && $topicAuthor-
<?= htmlentities($topic->title) ?>
<div class="pull-right text-normal">
<?php if ($canEdit): ?>
- <button id="btn-edit-title" class="btn btn-default js-only"><span class="glyphicon glyphicon-pencil" aria-hidden="true"></span> Edit title</button>
+ <button id="btn-edit-title" class="btn btn-default js-only"><span class="glyphicon glyphicon-pencil" aria-hidden="true"></span> <?= __("Edit title") ?></button>
<?php endif; ?>
<?php if ($canReply): ?>
- <button id="btn-reply" class="btn btn-default js-only"><span class="glyphicon glyphicon-share-alt" aria-hidden="true"></span> Reply</button>
+ <button id="btn-reply" class="btn btn-default js-only"><span class="glyphicon glyphicon-share-alt" aria-hidden="true"></span> <?= __("Reply") ?></button>
<?php endif; ?>
<?php if ($canDelete): ?>
<form action="?_action=deletetopic" method="post" class="seamless-inline">
<input type="hidden" name="topic" value="<?= htmlentities($topic->id) ?>">
- <button type="submit" class="btn btn-danger"><span class="glyphicon glyphicon-trash" aria-hidden="true"></span> Delete topic</button>
+ <button type="submit" class="btn btn-danger"><span class="glyphicon glyphicon-trash" aria-hidden="true"></span> <?= __("Delete topic") ?></button>
</form>
<?php endif; ?>
</div>
</div><br>
- Started by
- <?php if ($topicAuthor !== null): ?>
- <a href="?_action=viewuser&amp;user=<?= htmlentities(urlencode($topicAuthor->id)) ?>"><?= htmlentities($topicAuthor->displayName) ?></a>
- <?php else: ?>
- <em>(deleted)</em>
- <?php endif; ?>
- on <span class="_time"><?= htmlentities($topic->creationDate->format("c")) ?></span>
+ <?= __("Started by %user% on %date%", [
+ "user" => ($topicAuthor !== null) ? ('<a href="?_action=viewuser&amp;user=' . htmlentities(urlencode($topicAuthor->id)) . '">' . htmlentities($topicAuthor->displayName) . '</a>') : __("(deleted)"),
+ "date" => '<span class="_time">' . htmlentities($topic->creationDate->format("c")) . '</span>',
+ ]); ?>
</div>
<?php if ($canEdit): ?>
- <form action="?_action=updatetopic" method="post" id="editHeading" style="display: none;" class="form-inline seamless-inline" style="display: block">
+ <form action="?_action=updatetopic" method="post" id="editHeading" style="display: none;" class="form-inline seamless-inline">
<input type="hidden" name="topic" value="<?= htmlentities(urlencode($topic->id)) ?>">
<div class="row">
<div class="col-md-8">
<input type="text" class="form-control" name="title" id="i_edit_title" data-original-value="<?= htmlentities($topic->title) ?>" value="<?= htmlentities($topic->title) ?>" style="box-sizing: border-box; width: 100%; font-size: 36px; height: 56px">
</div>
<div class="col-md-4 text-right">
- <button type="button" id="topicTitleEditCancel" class="btn btn-default"><span class="glyphicon glyphicon-remove" aria-hidden="true"></span> Cancel</button>
- <button type="submit" class="btn btn-success"><span class="glyphicon glyphicon-floppy-disk" aria-hidden="true"></span> Save changes</button>
+ <button type="button" id="topicTitleEditCancel" class="btn btn-default"><span class="glyphicon glyphicon-remove" aria-hidden="true"></span> <?= __("Cancel") ?></button>
+ <button type="submit" class="btn btn-success"><span class="glyphicon glyphicon-floppy-disk" aria-hidden="true"></span> <?= __("Save changes") ?></button>
</div>
</div>
</form>