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......

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/d931a8ae4fe7dc08/46a9a57134aa4439?lnk=gst&q=categories+pagination&rnum=2#46a9a57134aa4439
(Should be ok, but only for cake 1.2)

http://groups.google.com/group/cake-php/browse_thread/thread/d931a8ae4fe7dc08/46a9a57134aa4439?lnk=gst&q=categories+pagination&rnum=2#46a9a57134aa4439
(not under stand well for the coding)

http://bin.cakephp.org/saved/21687
http://www.nabble.com/Paginating-the-results-after-creating-a-dummy-model-to-filter-HABTM-results--t4056506.html
http://bakery.cakephp.org/articles/view/keeping-bindmodel-and-unbindmodel-out-of-your-controllers
( 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