473,786 Members | 2,428 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

"<<previous << 2 3 4 5 >>next>>" scheme

hi all,
I am creating a web project with php/mysql.
one of qeury result is too high. it returs several thousand rows.
But I can't show them in one page.
So I wanna create more than one pages
then I shall use "<<previous << 2 3 4 5 >>next>>" scheme.
but i don't have any idea.
If user clicks 3rd page. I shall show the 3rd page.
How should I do this ?
should I again query the whole or a portion ? what is the function
related to this.
Thank in advance

Aug 28 '06 #1
3 1724
Also sprach hSiplu:
I am creating a web project with php/mysql.
one of qeury result is too high. it returs several thousand rows.
But I can't show them in one page.
So I wanna create more than one pages
then I shall use "<<previous << 2 3 4 5 >>next>>" scheme.
but i don't have any idea.
If user clicks 3rd page. I shall show the 3rd page.
How should I do this ?
should I again query the whole or a portion ? what is the function
related to this.
You could use MySQL's LIMIT clause.
Aug 28 '06 #2
if I use
select * from t1 limit 10;
it shows first 10 returned rows.
It wont work.
it would work if an range could be used

Aug 29 '06 #3
oh
I have found it !
limit [offset,] row_count
that solves everything :)

Aug 29 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1555
by: Keith | last post by:
I have downloaded some sample code from the net to display a calendar etc. The code is below. How can I modify this code so that when called in a popup window and a date is clicked, that date is inserted into a form field on the original page. I know how to pass this value back but do not know how to modify this code to include the correct line. **** CODE FOLLOWS****
22
130421
by: stephen | last post by:
I have created an order form that users javascript to create a new html document when the customers clicks the "print page" button. Once the new document has been created it then prints the document and closes it with the following code: <body onload="window.print(); window.close();"> This works correctly (or at least the way I expect it to work under MS Internet Explorer, but it cuases Netscape to "crash"
2
2388
by: Jeff Gardner | last post by:
Greetings: I've a script written for paging through a given recordset with page links, etc. I want to be able to limit the number of page numbers displayed as a large query may result in 100 or more pages and having 100 or more page links is ugly, to say the least. Below is the code that I am using for the paging. I'd like something like pages 1 - 5, click 5 or next, then pages 6-10 are displayed, etc. I am not sure where to start as...
9
4049
by: deedub65 | last post by:
I am getting a "Missing ) after argument list" on two different sets of commands in the same script - they are part of Dreamweaver MX's files, so i am not sure how they got altered - thanks for the help! function canAcceptCommand() { // Make sure the focus is in the BODY of the document. var retVal = false; if (dw.getFocus() == 'document' && dw.getDocumentDOM().getFocus() == 'body') { retVal = true; } if...
32
3884
by: fran7 | last post by:
Hi, Trying to solve a problem with no knowledge of asp. I have a dropdown list populated from my database with card decription. The output is names like, abstract,illustration etc. I am sending the results to another page like so .. html directory.asp?PostCardID=XX .. Now the request.querystring I presume should be something like this. ..asp
83
4236
by: liketofindoutwhy | last post by:
I am learning more and more Prototype and Script.aculo.us and got the Bungee book... and wonder if I should get some books on jQuery (jQuery in Action, and Learning jQuery) and start learning about it too? Once I saw a website comparing Prototype to Java and jQuery to Ruby... but now that I read more and more about Prototype, it is said that Prototype actually came from Ruby on Rails development and the creator of Prototype created it...
5
13381
matheussousuke
by: matheussousuke | last post by:
Hello, I'm using tiny MCE plugin on my oscommerce and it is inserting my website URL when I use insert image function in the emails. The goal is: Make it send the email with the URL http://mghospedagem.com/images/controlpanel.jpg instead of http://mghospedagem.comhttp://mghospedagem.com/images/controlpanel.jpg As u see, there's the website URL before the image URL.
0
9647
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10360
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9960
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8988
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6744
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5397
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5532
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3668
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2894
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.