Skip to main content
Inspiring
December 17, 2010
解決済み

Recordset paging by A,B,C....instead of Next Page, Prev Page, etc.?

  • December 17, 2010
  • 返信数 1.
  • 6256 ビュー

Hello geniuses,

I was wondering if there is a way to do the following:

I currently have a member database (MySQL) that I manage for a client. Using DW CS4, I used the built-in Recordset paging to add a navigation bar to the top of the member listing, limiting it to 50 per page. Since there are so many members in this organization, my client has asked me to create an A,B,C...navigation bar, rather than First Page - Next Page - Prev Page - Last Page. Is there a way to do this? Note that if a member is added or dropped from the list and they happen to be the first of the B's (for example), then the marker has to move accordingly. Thanks for pointing me in the right direction.

Regards,

Gail

このトピックへの返信は締め切られました。
解決に役立った回答 Günter_Schenk

First, you were correct about the missing single quotes, and that solved

the problem. Thanks very much.

So, a feature it is! I guess there's no real harm done to load more at

the "first look" of the member list. It does work correctly for all

letters. You are right in that if I drop "maxusers" down to 10 or 20,

the bottom half of, say, the Bs, gets cut off.

I originally had the Recordset Paging Navigation Bar on my page, but my

client didn't like it because he had to page through and hunt for

members. Hence my determination to provide an A,B,C navigation for him,

which you have so kindly helped me with. I didn't think about using both

features - the paging navigation bar, plus the A,B,C navigation. That

would definitely solve the worry of someday going over 50 members in any

given letter and not noticing that the list is cut off. I'll add it back.

I want to thank you profusely for all your help on this. Not only have

you stuck with me, but your timely responses meant I could finish this

today. You are my new best friend!

Best regards,

Gail


Gail,

it´s been a real pleasure to participate in such an intense "dialogue", and I salute you for remaining persistent !

Cheers,

Günter

返信数 1

December 17, 2010

By A,B,C... do you mean that clicking on A will only show memebers whose name starts with A or do you mean like 1,2,3...10 etc where clicking on 1 will show the first 50 people that were entered into the DB? Please specify.

You can find useful information by searching for:

(your unmentioned server side scripting language) pagination

Gail Bergan作成者
Inspiring
December 17, 2010

I mean that clicking on A will only display those whose last names

start with A. Sorry for any confusion.

Gail

December 17, 2010

Your scripting language is still unmentioned.

On list page create links to yourwebsite.com/results?surname=a for a yourwebsite.com/results?surname=b for b etc.

In database create a column for surname and enter the first letter of the last name or use a function to retrieve the first letter of the last name and then create a variable out of that. Unfortunately vague solutions are provided when the server side scripting language is not provided by the poster.

On index page for results create a filtered recordset where URL parameter surname = the variable for the first letter of surname or the value of the surname databse column. Loop the results of the recordset on the results page.