Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3963618
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T03:14:12+00:00 2026-05-20T03:14:12+00:00

I am not a well-versed programmer so i don’t want to use a complicated

  • 0

I am not a well-versed programmer so i don’t want to use a complicated pagination. Is there an alternative to using a pagination like in my queries can i limit them to say 20 results and then if their are more than 20 results i can show a “next” button and then that button will further load the next results??

I only want “next” to show if there are 20> results? Any help will be appreciated. Thanks.

Code:

  $query="SELECT * FROM actresses where actress_id = '$actressid' and production_full_name LIKE '%$q%'";  
       $result=mysql_query($query);

        $num=mysql_numrows($result);

        mysql_close();

          echo "";

       $i=0;
         while ($i < $num) {

         $1=mysql_result($result,$i,"production_full_name");
           $2=mysql_result($result,$i,"production_id");
     $3=mysql_result($result,$i,"actress");


          echo "<br><div id=linkcontain><a id=slink   href=$data/actress.php?id=$2>$3</a><div id=production>$1</div></div>";

            echo "";

            $i++;
            }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T03:14:13+00:00Added an answer on May 20, 2026 at 3:14 am

    You could add a limit to your query.

    $lower_limit = $results_per_page * $page_number;
    $upper_limit = $lower_limit + $results_per_page
    
    ..and production_full_name LIKE '%$q%' LIMIT $lower_limit, $upper_limit
    

    Then make a conditional “next page” link

    if ($upper_limit > 20) echo '<a href="{page url}?page_number='.($page_number+1).'">Next</a>;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm not very well versed with regular expressions. I've had to use them, maybe
I use the ternary operator quite often but I've not been able to find
(New to Objective-C, but well versed in C/C++). Presently I have an Objective-C class
Firebug is showing this HTML tag as not well-formed: <a id=aHarita target=_blank style=margin-left: 5px;
Why is Xul app saying XML Parsing Error: not well-formed for: <browser class=AppBar type=content
A simple question I suppose, with a potentially complicated answer: Is the Windows SDK
I'm trying to use a stored procedure to do an insert on a main
Before I get pointed to one of those 'VS.' questions like below... ASP.NET webforms
I need to serialize browser parsed HTML DOM to well-format XML. In firefox (gecko),
I am really confused by the explanations given in RVM website. The relation between

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.