Hi,
I'm trying to display a record count of some sort on a page I'm working
on. For example, "Record 1 of 15". I can display the 1st number ok, but
I'm a bit confused on what the count function should look like for the
2nd number (15, in this case). Here is my current (not working) code.
: Michael O'Neal [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 09, 2001 9:32 AM
To: [EMAIL PROTECTED]
Subject: [PHP] Count function. (Newbie Question)
Hi,
I'm trying to display a record count of some sort on a page I'm working
on. For example, "Record 1 of 15". I can display the 1st
Look here as a starting point:
http://www.php.net/manual/en/function.mysql-num-rows.php
I don't know the exact answer to your question but I hope that this helps.
-- Rodney
Michael O'Neal wrote:
Hi,
I'm trying to display a record count of some sort on a page I'm working
on. For example,
Well, in this code, you are going to receive one line from your table that
displays the total number of records. And that is it. Here is a sample from
one of my tables, using the MySQL CLI:
mysql select count(*) from locker;
+--+
| count(*) |
+--+
| 47 |
+--+
1 row
Hi
There are 2 issues:
You need to maintain a page counter
You need to pass the page counter and the total page count from page to page
You can do this via url params
(xxx.html?page=$page_countrecord_count=$record_count), sessions or cookies
depending
HTH
Let me elaborate a little bit
AIL PROTECTED]]
Sent: Monday, April 09, 2001 9:53 AM
To: [EMAIL PROTECTED]
Subject: RE: [PHP] Count function. (Newbie Question)
Hi
There are 2 issues:
You need to maintain a page counter
You need to pass the page counter and the total page count from page to
page
You can do this via url p
Monday, April 09, 2001 9:53 AM
To: [EMAIL PROTECTED]
Subject: RE: [PHP] Count function. (Newbie Question)
Hi
There are 2 issues:
You need to maintain a page counter
You need to pass the page counter and the total page count from page to
page
You can do this via url params
(xxx.htm
7 matches
Mail list logo