Yes!! More of this!I've been struggling to get oejcbted-oriented for a while. I've read a lot of stuff for learning PHP OOP, but haven't been able to learn past the typical A property is , a method is , a car has properties: engine, wheels a car has methods: drive, reverse , etc. etc. , but never really learned how to utilize it in the web-development context. I'm still developing procedurally and it's getting a bit hard to maintain as I take on bigger projects.So I picked up and am currently a little over a quarter way through Matt Zandstra's PHP Objects, Patterns, and Practice and it has really helped me to break past that and learn more about class structure and design, although the examples are still a bit abstract (which I guess is a good thing when learning about design patterns). Your article has started to address my biggest questions such as what things should be built as objects and where should they be used, etc. The next step obviously is to study a framework like Yii.As for your article, one question I have is what about having that user data persist after say logging in? Would you have something like a session class which would have methods like init(), saveUser(User $user), and retrieveUser()?


トップ   一覧 検索 最終更新   ヘルプ   最終更新のRSS