|
Posted by NC on 01/21/06 23:28
neodem wrote:
>
> PHP, and to a lesser degree JSF has become very popular ways
> to build web applications. What I don't understand, and what I
> would like you all to comment on, is how these methods are the
> best way to build web applications.
There is no such thing as "the best way to build Web applications".
Rather, you must think of the "most appropriate" way, given the
applicaiton's level of complexity, preferences regarding the operating
system and database back-end, development time and cost considerations,
and, perhaps, availability of a foundation product (i.e., a third-party
product that can be quickly extended to required functional
specifications).
> I come from the traditional Struts/JAVA world and the traditional
> MVC archetecture. It seems to me, and I could be wrong, that
> PHP and JSF seem to be pulling more business and data layer
> code up to the View Layer. I don't see how this is a good thing.
Very simple. It's faster to develop from scratch. Also, not everyone
is convinced that OOP is such a good idea. Once you realize that you
need not be shackled by OOP and can go back to good old procedural
programming any time you want, adherence to any object-oriented
architecture becomes a moot point.
> Wouldn't it be better to use the traditional method and keep the
> code out of the view? How does one maintain the code?
You are assuming that code needs to be maintained, which is not always
the case. Think of rapid prototyping, for example; you want to build
the prototype quickly, knowing full well that (1) there is no guarantee
that the application will evolve past the prototype, and (2) if the
application does in fact evolve past the prototype, there is no
guarantee that the production version will be written in the same
language the prototype was. In this case, the use of a framework will
only add to the cost of prototyping...
> Can someone give me an idea of where I am wrong?
On two counts: (1) OOP is not the only way to program in PHP, and (2)
not every application is meant to be maintained.
Cheers,
NC
[Back to original message]
|