From an OOP point of view, how can I create a DAO (data access object) in php?
For example (using an account as a basic example), my AccountDAO will perform the following functions:
GetAllAccountsGetAccountByIDUpdateAccountDeleteAccountInsertAccount
So, as soon as I get all the accounts in the database, should I return them to the caller as an array of account objects? Should I just return the mysql result set?
Do you know a good example of a DAO?
carlg source
share