Hi!
(not sure where to put this topic, here or in the "MySQL section)
Background: I'm trying to design a simple php game just to put my newfound OO Modeling and Design skills to the test.
Since I'm going OO all out there will be alot of classes and many objects will contain arrays of other objects which in turn have attributes that I will need to store somehow.
I've worked with MySQL and PHP before when creating a calender and a login system, but at that time I didn't even realise that PHP could be used as a OO language.
Problem: How do I store objects in a database that aren't of any primitive type.
How do I store objects that contain other objects?
I thought about giving each class a function called "storeMe" or something which returns an array or string of the attributes. That would require another function "restoreMe" to rebuild all the info again. However, I was hoping there would be an easier way.
Also, is it possible to store pictures in a MySQL database?