I've done something similar. I've pasted the code here:

http://bin.cakephp.org/view/661736473

Basically, the code will allow for listing Members by last name, one
set per initial letter. Both the method for obtaining the results by
letter and the list of alphabetical links (where letters for which
there are no matches are presented as spans) are shown.

Note that this is not yet in production! I still have to do something
about caching, for instance.And paginating the results for a pecific
letter might be desired. It's not an issue for me just now and I'm not
sure I'll bother adding that functionality. It'd be nice to get this
refactored into a tidier, more gernalised package, though.

This code was modified from an existing non-Cake app which utilised
pl/Python in Postgres DB. I've rewritten it for use with a Cake app
that uses ~sigh~ MySQL.

Additionally, my setup is pretty complex so I've tried to generalise
this code a bit. Hopefully, this will give you some insight.

Also, I wouldn't be surprised if there's an altogether simpler way to
go about this.

On Sun, Feb 8, 2009 at 6:07 AM, GetIT <david.bruen...@t-online.de> wrote:
>
> Hi,
>
> I want to create an adress book.
> The names should be displayed with a pagination but not in the
> "normal". Not x entries on one page, but all names beginnining with an
> "A" on one side, all with "B" on one side and so on.
>
> Has anyone expiriences or with that or an idea how to solve that?
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to