Archived
1
0

Small changes

This commit is contained in:
Marcel 2018-10-28 15:33:06 +01:00
parent bc30382947
commit 2af398f730
162 changed files with 81 additions and 58 deletions

View File

@ -53,4 +53,11 @@
$lang['feed_search_posts'] = 'Posts'; $lang['feed_search_posts'] = 'Posts';
$lang['feed_search_media'] = 'Medien'; $lang['feed_search_media'] = 'Medien';
$lang['post_reply_to'] = 'als Antwort an';
$lang['post_reply'] = 'Antworten';
$lang['post_no_replies'] = 'Es gibt zu diesem Post keine Antworten. Wie wär\'s, wenn du der Erste bist, eine zu verfassen?';
$lang['post_like'] = 'Gefällt mir';
$lang['post_like_account_missing'] = 'Du musst eingeloggt sein, um Posts zu bewerten. <a href="' . base_url('login') . '" class="alert-link">Erstelle dir kostenlos einen Account oder melde dich an.</a>'; $lang['post_like_account_missing'] = 'Du musst eingeloggt sein, um Posts zu bewerten. <a href="' . base_url('login') . '" class="alert-link">Erstelle dir kostenlos einen Account oder melde dich an.</a>';
$lang['post_copy_link'] = 'Link zum Post kopieren';
$lang['post_report'] = 'Post melden';
$lang['post_delete'] = 'Post löschen';

View File

@ -52,3 +52,12 @@
$lang['feed_search_user'] = 'Users'; $lang['feed_search_user'] = 'Users';
$lang['feed_search_posts'] = 'Posts'; $lang['feed_search_posts'] = 'Posts';
$lang['feed_search_media'] = 'Media'; $lang['feed_search_media'] = 'Media';
$lang['post_reply_to'] = 'as a reply to';
$lang['post_reply'] = 'Reply';
$lang['post_no_replies'] = 'There are no replies to this post currently. How about you\'re becoming the first one to write a reply?';
$lang['post_like'] = 'Like';
$lang['post_like_account_missing'] = 'You have to be logged in to like posts. <a href="' . base_url('login') . '" class="alert-link">Create a new account for free now or sign in with an existing profile.</a>';
$lang['post_copy_link'] = 'Copy Post Link';
$lang['post_report'] = 'Report Post';
$lang['post_delete'] = 'Delete Post';

View File

@ -1,9 +1,10 @@
<?php <?php
defined('BASEPATH') OR exit('No direct script access allowed'); defined('BASEPATH') OR exit('No direct script access allowed');
use Coduo\PHPHumanizer\DateTimeHumanizer; use Coduo\PHPHumanizer\DateTimeHumanizer;
class GeneralModel extends CI_Model { class GeneralModel extends CI_Model
{
function __construct() function __construct()
{ {
@ -17,26 +18,30 @@ class GeneralModel extends CI_Model {
$posts = $this->BlogModel->getMostRecentPosts($count); $posts = $this->BlogModel->getMostRecentPosts($count);
$return = ''; $return = '';
foreach($posts as $result) { foreach ($posts as $result) {
$date = strtotime($result['postPublishDate']); $date = strtotime($result['postPublishDate']);
$return .= '<div class="media"> $return .= '<div class="media">';
<div class="pull-left">
<img src="' . $result['postImage'] . '?w=100" style="max-width:100px" class="img-fluid"> if ($result['postImage'] != '') {
</div> $return .= '<img src="' . $result['postImage'] . '?w=100" style="width:75px" class="img-fluid mr-3">';
<div class="media-body"> }
<span class="media-heading"><a href="#">' . $result['postTitle'] . '</a></span>
<small class="muted">' . lang('footer_published') . ' ' . DateTimeHumanizer::difference(new \DateTime(), new \DateTime("@$date"), $_SESSION['site_lang']) . '</small> $return .= '<div class="media-body">
<h6 class="my-0"><a href="#">' . $result['postTitle'] . '</a></h6>
<small class="text-white-50">' . lang('footer_published') . ' ' . DateTimeHumanizer::difference(new \DateTime(), new \DateTime("@$date"), $_SESSION['site_lang']) . '</small>
</div> </div>
</div>'; </div>';
} }
return $return; return $return;
} }
function addFeedbackAnonymously($pageUrl, $message) { function addFeedbackAnonymously($pageUrl, $message)
{
$this->addFeedback($pageUrl, $message, true, NULL, NULL); $this->addFeedback($pageUrl, $message, true, NULL, NULL);
} }
function addFeedback($pageUrl, $message, $anonymous, $userID, $email) { function addFeedback($pageUrl, $message, $anonymous, $userID, $email)
{
$this->db->query('INSERT INTO feedback (page, message, anonymous, userID, email) VALUES (?, ?, ?, ?, ?)', [$pageUrl, $message, $anonymous, $userID, $email]); $this->db->query('INSERT INTO feedback (page, message, anonymous, userID, email) VALUES (?, ?, ?, ?, ?)', [$pageUrl, $message, $anonymous, $userID, $email]);
$this->db->cache_delete('admin', 'feedback'); $this->db->cache_delete('admin', 'feedback');
@ -44,7 +49,8 @@ class GeneralModel extends CI_Model {
$this->NotificationModel->rankNotificationNewFeedback($userID != NULL ? $userID : -1, 9, $pageUrl); $this->NotificationModel->rankNotificationNewFeedback($userID != NULL ? $userID : -1, 9, $pageUrl);
} }
function getRankName($rankID) { function getRankName($rankID)
{
$ranks = [ $ranks = [
0 => "Nutzer", 0 => "Nutzer",
1 => "Registrierter Nutzer", 1 => "Registrierter Nutzer",
@ -59,4 +65,4 @@ class GeneralModel extends CI_Model {
return isset($ranks[$rankID]) ? $ranks[$rankID] : "Nutzer"; return isset($ranks[$rankID]) ? $ranks[$rankID] : "Nutzer";
} }
} }

View File

@ -23,7 +23,7 @@
<?php if ($reply_to != NULL): ?> <?php if ($reply_to != NULL): ?>
<small> <small>
<i class="fa fa-reply"></i> <i class="fa fa-reply"></i>
als Antwort an <?= lang('post_reply_to') ?>
<a href="#" onclick="showFullPost('<?= $replyToPost['uuid'] ?>', '<?= $replyToPost['username'] ?>')">@<?= $replyToPost['displayname'] ?></a> <a href="#" onclick="showFullPost('<?= $replyToPost['uuid'] ?>', '<?= $replyToPost['username'] ?>')">@<?= $replyToPost['displayname'] ?></a>
</small> </small>
<?php endif; ?> <?php endif; ?>
@ -45,11 +45,11 @@
</div> </div>
<?php if (!isset($hideActionBtns) || !$hideActionBtns): ?> <?php if (!isset($hideActionBtns) || !$hideActionBtns): ?>
<div class="action-btns"> <div class="action-btns">
<a href="#" data-uuid="<?= $uuid ?>" class="action-btn reply-button" data-toggle="tooltip" data-placement="top" title="Antworten"> <a href="#" data-uuid="<?= $uuid ?>" class="action-btn reply-button" data-toggle="tooltip" data-placement="top" title="<?= lang('post_reply') ?>">
<i class="far fa-comment"></i> <i class="far fa-comment"></i>
<span><?= $replyCount ?></span> <span><?= $replyCount ?></span>
</a> </a>
<a href="#" data-uuid="<?= $uuid ?>" class="action-btn like-button <?= isset($userHasLiked) && $userHasLiked ? 'active' : '' ?>" data-toggle="tooltip" data-placement="top" title="Gefällt mir"> <a href="#" data-uuid="<?= $uuid ?>" class="action-btn like-button <?= isset($userHasLiked) && $userHasLiked ? 'active' : '' ?>" data-toggle="tooltip" data-placement="top" title="<?= lang('post_like') ?>">
<i class="<?= isset($userHasLiked) && $userHasLiked ? 'fas' : 'far' ?> fa-heart"></i> <i class="<?= isset($userHasLiked) && $userHasLiked ? 'fas' : 'far' ?> fa-heart"></i>
<span><?= $likeCount ?></span> <span><?= $likeCount ?></span>
</a> </a>
@ -61,17 +61,17 @@
<div class="dropdown-menu" aria-labelledby="postMoreOptionsButton<?= $uuid ?>"> <div class="dropdown-menu" aria-labelledby="postMoreOptionsButton<?= $uuid ?>">
<a href="#" onclick="copyToClipboard('<?= base_url('user/' . $username . '/post/' . $uuid) ?>')" class="dropdown-item"> <a href="#" onclick="copyToClipboard('<?= base_url('user/' . $username . '/post/' . $uuid) ?>')" class="dropdown-item">
<i class="fa fa-copy"></i> <i class="fa fa-copy"></i>
Link zum Post kopieren <?= lang('post_copy_link') ?>
</a> </a>
<a href="#" onclick="openPostReportModal('<?= $uuid ?>')" class="dropdown-item"> <a href="#" onclick="openPostReportModal('<?= $uuid ?>')" class="dropdown-item">
<i class="fa fa-flag"></i> <i class="fa fa-flag"></i>
Post melden <?= lang('post_report') ?>
</a> </a>
<?php if (isset($_SESSION['user']) && $_SESSION['user']['username'] == $username): ?> <?php if (isset($_SESSION['user']) && $_SESSION['user']['username'] == $username): ?>
<div class="dropdown-divider"></div> <div class="dropdown-divider"></div>
<a href="#" onclick="openDeletePostModal('<?= $uuid ?>')" class="dropdown-item text-danger"> <a href="#" onclick="openDeletePostModal('<?= $uuid ?>')" class="dropdown-item text-danger">
<i class="fa fa-trash"></i> <i class="fa fa-trash"></i>
Post löschen <?= lang('post_delete') ?>
</a> </a>
<?php endif; ?> <?php endif; ?>
</div> </div>

View File

@ -97,7 +97,7 @@
<?php else: ?> <?php else: ?>
<p class="text-muted"> <p class="text-muted">
<i class="far fa-frown"></i> <i class="far fa-frown"></i>
Es gibt zu diesem Post keine Antworten. Wie wär's, wenn du der Erste bist, eine zu verfassen? <?= lang('post_no_replies') ?>
</p> </p>
<?php endif; ?> <?php endif; ?>
</div> </div>

View File

@ -1253,6 +1253,7 @@ ul#downloadSlider a.active .overlay {
.comment-list .blog-post-item .comment-well { .comment-list .blog-post-item .comment-well {
height: 100px; height: 100px;
padding: 0;
} }
.comment-list .blog-post-item .comment-well .entry-image { .comment-list .blog-post-item .comment-well .entry-image {

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 143 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 603 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 223 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 134 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 464 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 180 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 53 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 66 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 315 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

Some files were not shown because too many files have changed in this diff Show More