The result is the first page that displays only the contents of the database, and clicking the next page still stays on the first page.
There are currently ". $count." Record total ". $pages." Page "; if ($offset) {$preoffset = $offset-$list _num;print "Previous";} else {echo "prev";} $newoffset = $offset + $list _num; if ($pages!=0) && (($newoffset/$list _num)! = $pages)) {print ("next page");} else{echo "Next page",} $pageno = ($offset/$list _num) +1;echo "sectionPage "; ? >
Reply to discussion (solution)
You use the chrome review element to see "next page" This place has no connection,
Then there is the one you used to tell you the landlord that day
Abstract ($_request); This is going to be added to the top
There are currently ". $count." Record total ". $pages." Page "; if ($offset) { $preoffset = $offset-$list _num; Print "Previous page";} else { echo "prev"; } $newoffset = $offset +1;//$list _num; if ($pages!=0) && (($newoffset/$list _num)! = $pages)) { print ("next page"); } else{echo "next page";} $pageno = $offset; echo "sectionPage "; ? >
I don't know if I misunderstood LZ's meaning.
There are currently ". $count." Record total ". $pages." Page "; if ($offset) { $preoffset = $offset-$list _num; Print "Previous page";} else { echo "prev"; } $newoffset = $offset +1;//$list _num; if ($pages!=0) && (($newoffset/$list _num)! = $pages)) { print ("next page"); } else{echo "next page";} $pageno = $offset; echo "sectionPage "; ? >
Do not know is not misunderstood the LZ's meaning I used your code, although the bottom page after the bottom of the display is the second, but the contents of the form is the first page ah?
There are currently ". $count." Record total ". $pages." Page "; if ($offset) { $preoffset = $offset-$list _num; Print "Previous page";} else { echo "prev"; } $newoffset = $offset +1;//$list _num; if ($pages!=0) && (($newoffset/$list _num)! = $pages)) { print ("next page"); } else{echo "next page";} $pageno = $offset; echo "sectionPage "; ? >
Do not know is not misunderstood the LZ means that the page is changing, the content is unchanged.
As for the SQL statement of the database, I'm not quite sure how it was written.
Typically select * from ' table ' ORDER BY id DESC LIMIT 1 $offset * $count/$list _num, ($offset + 1) * $count/$list _num
The following code has been tested with my own database and can be run
There are currently ". $count." Record total ". $pages." Page "; if ($offset) { $preoffset = $offset-1; Print "Previous page";} else { echo "prev"; } $newoffset = $offset +1;//$list _num; if ($pages!=0) && (($newoffset/$list _num)! = $pages)) { print ("next page"); } else{echo "next page";} $pageno = $offset; echo "sectionPage "; ? >
As for the SQL statement of the database I'm not quite sure how it was written.
is generally select * from ' table ' ORDER BY id DESC LIMIT 1 $offset * $count/$list _num, ($offset + 1) * $count/$list _num
The following generation The code has been tested with my own database and can run
There are currently ". $count." Record total ". $pages." Page "; if ($offset) { $preoffset = $offset-1; Print "Previous page";} else { echo "prev"; } $newoffset = $offset +1;//$list _num; if ($pages!=0) && (($newoffset/$list _num)! = $pages)) { print ("next page"); } else{echo "next page";} $pageno = $offset; echo "sectionPage "; ? >
Thanks a lot!