Commit:    e471466e32ba7882ab08038de14a300deb8d1a8b
Author:    Sobak <msobaczew...@gmail.com>         Sun, 19 Apr 2020 12:59:43 
+0200
Parents:   b8cf248dc8fc004b41367dc9979af6fc778daf98
Branches:  master

Link:       
http://git.php.net/?p=web/master.git;a=commitdiff;h=e471466e32ba7882ab08038de14a300deb8d1a8b

Log:
Final attempt to fix pagination?

Changed paths:
  M  manage/user-notes.php


Diff:
diff --git a/manage/user-notes.php b/manage/user-notes.php
index da2145c..00c397f 100644
--- a/manage/user-notes.php
+++ b/manage/user-notes.php
@@ -375,19 +375,10 @@ if (!$action) {
              "number of votes placed in a small timeframe to help detect spam 
and other potential abuse.</p>\n".
              "<p>Also note that a <em>0.0.0.0</em> IP address indicates a 
client IP could not be resolved at the time of voting.</p>";
       }
-      // Temp debug
-      // @todo remove
-      echo '<!-- ';
-      print_r($_REQUEST, false);
-      print_r($search_votes, false);
-      echo ' -->';
-      if((isset($_REQUEST["view"]) || isset($_REQUEST['keyword'])) && 
isset($search_votes) && $search_votes === true) {
+      if((isset($_REQUEST["view"]) || isset($_REQUEST['keyword'])) && 
empty($search_votes)) {
         $keyword = isset($_REQUEST['keyword']) ? '&keyword=' . 
urlencode($_REQUEST['keyword']) : '';
-        // Setting type is here only to avoid notice or more conditions.
-        // It won't cause to show last notes (type=0) as $_REQUEST['keyword'] 
presence has higher priority.
-        $type = 0;
         echo "<p><a href=\"?view=notes&page=$page&type=$type$keyword\">Next 
10</a>";
-      } elseif (isset($_REQUEST["view"]) && isset($search_votes) === false) {
+      } elseif (isset($_REQUEST["view"]) && !empty($search_votes)) {
         echo "<p>";
         if (isset($NextPage) && $NextPage > 1) {
           echo "<a 
href=\"?view=notes&page=$PrevPage&type=$type{$isSearch}\">&lt; Prev 25</a> ";


--
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to