parent
9f1bf68d9b
commit
66f9dbab26
32
php/home.php
32
php/home.php
@ -31,25 +31,23 @@ $pageHandler = new Pages();
|
|||||||
$previousLink = null;
|
$previousLink = null;
|
||||||
$nextLink = null;
|
$nextLink = null;
|
||||||
$areTherePages = !!count($content);
|
$areTherePages = !!count($content);
|
||||||
if ( ( $isPage || $isHome ) ) {
|
if ( $isPage && $areTherePages ) {
|
||||||
if ( $isPage && $areTherePages ) {
|
$currentPage = $content[0];
|
||||||
$currentPage = $content[0];
|
if( isset($currentPage) ) {
|
||||||
if( isset($currentPage) ) {
|
if ( $currentPage->previousKey() ) {
|
||||||
if ( $currentPage->previousKey() ) {
|
$previousLink = buildPage($currentPage->previousKey())->permalink();
|
||||||
$previousLink = buildPage($currentPage->previousKey())->permalink();
|
}
|
||||||
}
|
if ( $currentPage->nextKey() ) {
|
||||||
if ( $currentPage->nextKey() ) {
|
$nextLink = buildPage($currentPage->nextKey())->permalink();
|
||||||
$nextLink = buildPage($currentPage->nextKey())->permalink();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ( $isHome ) {
|
}
|
||||||
if ( Paginator::showPrev() ) {
|
if ( $isHome ) {
|
||||||
$previousLink = Paginator::previousPageUrl();
|
if ( Paginator::showPrev() ) {
|
||||||
}
|
$previousLink = Paginator::previousPageUrl();
|
||||||
if ( Paginator::showNext() ) {
|
}
|
||||||
$nextLink = Paginator::nextPageUrl();
|
if ( Paginator::showNext() ) {
|
||||||
}
|
$nextLink = Paginator::nextPageUrl();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
Loading…
Reference in New Issue
Block a user