Re: On large application organization [long and possibly boring]

From: Date: Fri, 07 Jan 2005 01:13:08 +0000
Subject: Re: On large application organization [long and possibly boring]
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-205799@lists.php.net to get a copy of this message
Otherwise, I'm curious as to why you're using a large switch, not that it's bad inherently IMHO, but there may be a better overall approach. /jw
I don't know why *he* wants to do it, but one useful example is the MVC model (google "MVC phppatterns" if you're unfamiliar with the term). For a given action he can include the class definitions he will need to perform that action. Jay, are you using PHP5? Because if you are then I thought of something else. You can put each class into its own file and define your own __autoload() function to include a file "just in time". The main downside to this is if you use someone else's code and they have also defined their own __autoload() function then you get an error! :( -- Teach a person to fish... Ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html PHP Manual: http://php.net/manual/ php-general archives: http://marc.theaimsgroup.com/?l=php-general&w=2

« previous php.general (#205799) next »