replace prev/next

This commit is contained in:
Alex Grintsvayg 2016-07-14 09:41:21 -04:00
parent 5ba3ecacf4
commit 40ee4ec39a
2 changed files with 4 additions and 1 deletions

View file

@ -165,7 +165,7 @@ class Post
public function hasPrevNext() public function hasPrevNext()
{ {
return $this->postType == 'post'; return $this->postType == 'news';
} }
public function getAuthorName() public function getAuthorName()

View file

@ -22,6 +22,9 @@
<div class="content"> <div class="content">
<?php echo $post->getContentHtml() ?> <?php echo $post->getContentHtml() ?>
</div> </div>
<?php if ($post->hasPrevNext()): ?>
<?php echo View::render('content/_postNav', ['post' => $post]) ?>
<?php endif ?>
</section> </section>
<?php echo View::render('nav/_learnFooter', ['isDark' => false]) ?> <?php echo View::render('nav/_learnFooter', ['isDark' => false]) ?>