aboutsummaryrefslogtreecommitdiffstats
path: root/views
diff options
context:
space:
mode:
Diffstat (limited to 'views')
-rw-r--r--views/base.php37
-rw-r--r--views/index.php14
-rw-r--r--views/post.php4
3 files changed, 25 insertions, 30 deletions
diff --git a/views/base.php b/views/base.php
index dc52cd7..9e9e392 100644
--- a/views/base.php
+++ b/views/base.php
@@ -6,35 +6,30 @@
<!-- Generated on <?php echo $this->e($generatedOn); ?> -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<title><?php echo $this->e($blogTitle); ?> - <?php echo $this->e($pageTitle); ?></title>
- <link rel="stylesheet" type="text/css" href="<?php echo $this->e($requestRoot); ?>css/bootstrap-reboot.css">
- <link rel="stylesheet" type="text/css" href="<?php echo $this->e($requestRoot); ?>css/screen.css">
+ <link rel="stylesheet" type="text/css" href="<?php echo $this->e($requestRoot); ?>css/simple.css">
</head>
<body>
- <div class="header">
+<header>
<h1><?php echo $this->e($blogTitle); ?></h1>
-<?php if ('' !== $blogDescription): ?>
+<?php if ('' !== $blogDescription) { ?>
<h2><?php echo $this->e($blogDescription); ?></h2>
-<?php endif; ?>
- <ul class="pages">
-<?php foreach ($pagesList as $p): ?>
-<?php if ($p['fileName'] === $activePage): ?>
- <li class="active">
+<?php } ?>
+<nav>
+<?php foreach ($pagesList as $p) { ?>
+<?php if ($p['fileName'] === $activePage) { ?>
<a href="<?php echo $this->e($requestRoot); ?><?php echo $this->e($p['fileName']); ?>"><?php echo $this->e($p['title']); ?></a>
- </li>
-<?php else: ?>
- <li>
+<?php } else { ?>
<a href="<?php echo $this->e($requestRoot); ?><?php echo $this->e($p['fileName']); ?>"><?php echo $this->e($p['title']); ?></a>
- </li>
-<?php endif; ?>
-<?php endforeach; ?>
- </ul>
- </div> <!-- /header -->
- <div class="content">
+<?php } ?>
+<?php } ?>
+</nav>
+</header>
+<main>
<?php echo $this->section('content'); ?>
- </div> <!-- /content -->
+</main>
- <div class="footer">
+<footer>
<p>&copy; <?php echo $this->e($currentYear); ?> <?php echo $this->e($blogAuthor); ?></p>
- </div> <!-- /footer -->
+</footer>
</body>
</html>
diff --git a/views/index.php b/views/index.php
index 319f617..f969f82 100644
--- a/views/index.php
+++ b/views/index.php
@@ -1,12 +1,12 @@
-<?php foreach ($postsYearList as $year => $postsList): ?>
-<h3><?=$this->e($year); ?></h3>
+<?php foreach ($postsYearList as $year => $postsList) { ?>
+<h3><?php echo $this->e($year); ?></h3>
<ul class="index">
-<?php foreach ($postsList as $post): ?>
-<?php if ($post['publish']): ?>
+<?php foreach ($postsList as $post) { ?>
+<?php if ($post['publish']) { ?>
<li>
<a href="blog/<?php echo $this->e($post['fileName']); ?>"><?php echo $this->e($post['title']); ?></a> <small><?php echo $this->e($post['published']); ?></small>
</li>
-<?php endif; ?>
-<?php endforeach; ?>
+<?php } ?>
+<?php } ?>
</ul>
-<?php endforeach; ?>
+<?php } ?>
diff --git a/views/post.php b/views/post.php
index 491dc07..50a70a0 100644
--- a/views/post.php
+++ b/views/post.php
@@ -8,8 +8,8 @@
</p>
<?php echo $post['htmlContent']; ?>
-<?php if ($post['modified']): ?>
+<?php if ($post['modified']) { ?>
<p class="center"><small>Last Modified on <?php echo $this->e($post['modified']); ?></small></p>
-<?php endif; ?>
+<?php } ?>
<p class="center"><small><a href="<?php echo $this->e($post['postHistory']); ?>">History</a></small></p>
<?php $this->stop('content'); ?>