On Oct 11, 6:14 pm, Alpha <[EMAIL PROTECTED]> wrote:
> I have simply two table
>
> Products
> -id
> -name
> -category_id
>
> Categories
> -id
> -name
>
> Product  $belongsTo Category with foreign key category_id
> Category $hasMany Product  with foreign key category_id
>
> Views / Controllers are then cooked up, really nice~
> Index view of the Categories list all the category, Click View
> => The detail of the particular category come up with all the related
> Products
>
> My problem is to have the related Products Paginated......

hi,

You mean you view the Category and want to see and paginate the
related products?

Easiest way it to make /products/byCategory/$catId work. I.e. display
in that page the Category details and then do exactly the same as you
would with the index.

hth,

AD

>
> I make use with the package from Andy (http://bakery.cakephp.org/
> articles/view/pagination), and successfully make the individual
> product / category view  paginated, however, no way to work for the
> Related Products @ Category View...
>
> I have google all around to the possible solution with no luck...
>
> http://groups.google.com/group/cake-php/browse_thread/thread/d931a8ae...
> (Should be ok, but only for cake 1.2)
>
> http://groups.google.com/group/cake-php/browse_thread/thread/d931a8ae...
> (not under stand well for the coding)
>
> http://bin.cakephp.org/saved/21687http://www.nabble.com/Paginating-the-results-after-creating-a-dummy-m...http://bakery.cakephp.org/articles/view/keeping-bindmodel-and-unbindm...
> ( not understand well without details....)
>
> Somehow, $use => array { product, category} , maybe useful....
>
> Sorry that I'm new to Cake, and not Smart to get the things solved....
> I have spend four days more for the question which may not be
> difficult, any guide / help / hint is highly appreciated.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to