bibis/view/user.php

17 行
555 B
PHP

<?php
// User profile
?>
<dl>
<dt><b><?= htmlspecialchars($view['user']['username'] ?? '') ?></b> @<?= htmlspecialchars($view['user']['id']) ?></dt>
<?php if ($view['bio'] > ''): ?>
<dd><?= $view['bio'] /* bio is safe */ ?></dd>
<?php endif; ?>
<dd><b><?= $view['post_count'] ?></b> posts</dd>
</dl>
<?php if (isset($view['user']) && isset($_SESSION['user']) && $view['user']['id'] === $_SESSION['user']['id']): ?>
<ul>
<li><a href="<?= sitebase('setting/') ?>">ユーザー情報変更(Edit)</a>
</ul>
<?php endif; ?>
<h2>書き込み一覧・Posts</h2>