I have a project where I need a user to be able to add items to his favorites like this:
Items
- Item 1
- Item 2
- Item 3
Users
- User 1
- Favorites
- Item 1
- Item 3
- User 1
- Favorites
- Item 2
Can anyone help by suggesting a good way to structure my data?
EDIT 1:
Sorry I should have explained this in the initial question. So I have a main list which shows all the items and their data from the database. Then each user has the ability to save an item he likes. After that on that user's page he should be able to view all the items he has saved.
Okay so far so good, but the only way I can think of to save the item in the user Favorites list is to save its ID there. Now there is a problem. I want to show the data of the item not just it's ID.