This is my first attempt with CakePHP ever and my first development since long time ago so please bear with me
My solution to a probelm is as follow:
I have a table/model called Contents that has the following fields:
This table contain some contents that is associated with the records in different models/tables. The ‘reference_id’ contains the id of the record in other tables, just like a foreign key. However it is not associated with a speciifc table but based on the value of ‘model’ I will know where should I look for the record.
Is this a good approach for CakePHP framework or should I have separte Contents table for each model that needs it? If it is good how should I code the association?