<?php

/**
 * This file is part of JohnCMS Content Management System.
 *
 * @copyright JohnCMS Community
 * @license   https://opensource.org/licenses/GPL-3.0 GPL-3.0
 * @link      https://johncms.com JohnCMS Project
 */

/**
 * @var string $who_url
 * @var string $who_name
 * @var array $online
 */
?>
<div class="d-flex mt-2 pt-3 pb-3 align-items-center">
    <?php if (! empty($online)): ?>
        <div class="pr-3 d-flex align-items-center">
            <?php if ($user->isValid()): ?>
                <a href="<?= $who_url ?>" class="pr-1"><?= $who_name ?></a>
            <?php else: ?>
                <span class="pr-1"><?= $who_name ?></span>
            <?php endif; ?>
            <span class="badge badge-pill badge-secondary"><?= $online['online_u'] . '&#160;/&#160;' . $online['online_g'] ?></span>
        </div>
    <?php endif; ?>
    <div>
        <a href="/help/?act=forum"><?= __('Forum rules') ?></a>
    </div>
</div>
