Archived
1
0
This repository has been archived on 2020-12-10. You can view files and clone it, but cannot push or open issues or pull requests.
old/application/views/admin/user_details.php

91 lines
4.7 KiB
PHP

<?php
defined('BASEPATH') OR exit('No direct script access allowed');
use Coduo\PHPHumanizer\DateTimeHumanizer;
?>
<div class="right_col" role="main">
<div class="">
<div class="row">
<div class="col-md-6 col-sm-6 col-xs-6">
<div class="x_panel">
<div class="x_title">
<h2>Details zum Nutzer <?= $user['displayname'] ?></h2>
<div class="clearfix"></div>
</div>
<div class="x_content">
<div class="row">
<div class="col-sm-2">
<img src="<?= $user['profilePicture'] ?>" class="img-fluid">
</div>
<div class="col-sm-10">
<h3><a href="<?= base_url('user/' . $user['username']) ?>"
target="_blank"><?= $user['displayname'] ?></a></h3>
<?php $created_at = strtotime($user['dateCreated']); ?>
<p>
<b>Account erstellt: </b>
<?= DateTimeHumanizer::difference(new \DateTime(), new \DateTime("@$created_at"), "de_DE") ?>
<i>(<?= date("d.m.Y H:i", $created_at) ?>)</i>
</p>
<p><b>Originaler Name:</b> <?= $user['originalName'] ?></p>
</div>
</div>
<div class="row col-sm-12">
<p>
<b>Letzer Login:</b>
<?php $lastLogin = strtotime($user['lastLogin']) ?>
<?= DateTimeHumanizer::difference(new \DateTime(), new \DateTime("@$lastLogin"), "de_DE"); ?>
<i>(<?= date("d.m.Y H:i", $lastLogin) ?>)</i>
</p>
<p>
<b>E-Mail-Adresse:</b>
<a href="mailto:<?= $user['email'] ?>">
<?= $user['email'] ?>
</a>
</p>
<p>
<b>Rang:</b>
<?php $ranks = [0 => "Nutzer", 1 => "Registrierter Nutzer", 2 => "Premium-Nutzer", 3 => "Plus-Nutzer", 6 => "Autor", 7 => "Editor", 8 => "Moderator", 9 => "Semi-Admin", 10 => "Admin"]; ?>
<?= $ranks[$user['rank']] ?>
</p>
<p>
<b>Geschlecht:</b>
<?php $genders = ['male' => 'Männlich', 'female' => 'Weiblich', 'other' => 'Anderes', '' => 'Nicht Angegeben'] ?>
<?= $genders[$user['gender']] ?>
</p>
<p>
<b>Aktiviert?</b>
<?= $user['activated'] ? '<i class="fa fa-check-circle-o"></i> Ja' : '<i class="fa fa-times-circle-o"></i>Nein' ?>
</p>
<p>
<b>Zeige Werbung?</b>
<?= $user['showAds'] ? '<i class="fa fa-check-circle-o"></i> Ja' : '<i class="fa fa-times-circle-o"></i>Nein' ?>
</p>
<p>
<b>Biographie</b>
<?= $user['about'] ?>
</p>
<p>
<b>Sprache:</b>
<?= Locale::getDisplayName($user['language'], 'de') ?>
</p>
<p>
<b>Land:</b>
<?= Locale::getDisplayRegion('-' . $user['country'], 'de') ?>
</p>
<p>
<b>Erhalte E-Mails?</b>
<?= $user['receiveEmails'] ? '<i class="fa fa-check-circle-o"></i> Ja' : '<i class="fa fa-times-circle-o"></i>Nein' ?>
</p>
<p>
<b>Erhalte Newsletter?</b>
<?= $user['receiveNewsletter'] ? '<i class="fa fa-check-circle-o"></i> Ja' : '<i class="fa fa-times-circle-o"></i>Nein' ?>
</p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>