PHP Classes

I agree with the comment about the frameworks

Recommend this page to a friend!

      PHP Classes blog  >  4 Reasons Why All PHP...  >  All threads  >  I agree with the comment about the...  >  (Un) Subscribe thread alerts  
Subject:I agree with the comment about the...
Summary:Yes, all frameworks for php stinks!
Messages:3
Author:Jorge Castro
Date:2014-02-05 10:44:02
Update:2014-02-06 03:18:23
 

  1. I agree with the comment about the...   Reply   Report abuse  
Picture of Jorge Castro Jorge Castro - 2014-02-05 21:33:16
PHP is similar to some other languages, in special Java and C#. PHP supports, with some extends, classes, block of code, functions and so on. However, that's the only similarities.

PHP developers works different than Java or C#. Both, in Java and C# exists the concept of "application" or "project", where adding a class or library to the project is more than enough to be uses across all the application. In PHP is different, every file/library should be added manually AND PER CLIENT CALL.

PHP punish us with the use of libraries, the more (and biggest the library) then, the slower the system. In those cases, a big framework DOES NOT HELP AT ALL.

What's a smart php developer does?. Simply add every include only when it is needing, for example the PHPEXCEL library, it should be called only where it is needing.

In my current project, i use the next includes:
-a config file.
-a database library (single file without dependency).
-a html library (single file without dependency).
-a util library (single file without dependency).
-a DAO/DAL (per entity)
and nothing more.




  2. Re: I agree with the comment about the...   Reply   Report abuse  
Picture of Manuel Lemos Manuel Lemos - 2014-02-05 22:39:36 - In reply to message 1 from Jorge Castro
Right, that is basically what Rasmus is saying, use just small independent parts of a framework that your application needs, not whole collections of classes for all sorts of purposes you do not need.

  3. Re: I agree with the comment about the...   Reply   Report abuse  
Picture of Robi Robi - 2014-02-06 03:18:23 - In reply to message 2 from Manuel Lemos
good article, i bookmark this to be read by my boss