From 80c29b306e00e7e3ea496d4bc12197fbe69bceb1 Mon Sep 17 00:00:00 2001 From: danpros Date: Wed, 21 Apr 2021 20:38:28 +0700 Subject: [PATCH] Update functions.php --- system/includes/functions.php | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/system/includes/functions.php b/system/includes/functions.php index 75024a5..900784c 100644 --- a/system/includes/functions.php +++ b/system/includes/functions.php @@ -512,7 +512,7 @@ function get_category($category, $page, $perpage) } if (empty($tmp)) { - not_found(); + return false; } $tmp = array_unique($tmp, SORT_REGULAR); @@ -657,7 +657,7 @@ function get_type($type, $page, $perpage) } if (empty($tmp)) { - not_found(); + return false; } $tmp = array_unique($tmp, SORT_REGULAR); @@ -691,7 +691,7 @@ function get_tag($tag, $page, $perpage, $random) } if (empty($tmp)) { - not_found(); + return false; } $tmp = array_unique($tmp, SORT_REGULAR); @@ -714,7 +714,7 @@ function get_archive($req, $page, $perpage) } if (empty($tmp)) { - not_found(); + return false; } return $tmp = get_posts($tmp, $page, $perpage); @@ -736,7 +736,7 @@ function get_profile_posts($name, $page, $perpage) } if (empty($tmp)) { - return; + return false; } return $tmp = get_posts($tmp, $page, $perpage); @@ -761,7 +761,7 @@ function get_draft($profile, $page, $perpage) } if (empty($tmp)) { - return; + return false; } return $tmp = get_posts($tmp, $page, $perpage); @@ -969,7 +969,7 @@ function get_keyword($keyword, $page, $perpage) } if (empty($tmp)) { - return $tmp; + return false; } return $tmp = get_posts($tmp, $page, $perpage); @@ -1525,6 +1525,8 @@ function has_prev($prev) 'tag' => $prev->tag, 'category' => $prev->category, 'author' => $prev->author, + 'authorName' => $prev->authorName, + 'authorAbout' => $prev->authorAbout, 'authorUrl' => $prev->authorUrl, 'related' => $prev->related, 'views' => $prev->views, @@ -1555,6 +1557,8 @@ function has_next($next) 'tag' => $next->tag, 'category' => $next->category, 'author' => $next->author, + 'authorName' => $next->authorName, + 'authorAbout' => $next->authorAbout, 'authorUrl' => $next->authorUrl, 'related' => $next->related, 'views' => $next->views, @@ -1882,7 +1886,7 @@ function social($imgDir = null) function copyright() { $blogcp = blog_copyright(); - $credit = 'Proudly powered by HTMLy'; + $credit = 'Powered by HTMLy'; if (!empty($blogcp)) { return $copyright = '

' . $blogcp . '

' . $credit . '

'; @@ -2079,7 +2083,7 @@ function parseNode($node, $child = null) { return $li; } else { - if (isset($url['host'])) { + if (isset($url['host']) && isset($su['host'])) { if ($url['host'] == $su['host']) { if (slashUrl($url['path']) == slashUrl($req)) { $li = '