Thoughts on Professional PHP Development

By Angsuman Chakraborty, Gaea News Network
Friday, September 22, 2006

I have started developing an interesting PHP application for LAMP (Linux-Apache-MySQL-PHP) stack. I have to say it has been an wonderful experience so far.

It is rather simple (really simple) and easy to setup little frameworks (read utility functions in a file) in php for your tasks. PHP has a delicious array of functionalities to use. You have a very short code-test-debug cycle, very little configuration required, if any.

You don’t have to think about freeing resources, PHP does it for you (garbage collection like Java).
“Due to the reference-counting system introduced with PHP 4’s Zend Engine, it is automatically detected when a resource is no longer referred to (just like Java). When this is the case, all resources that were in use for this resource are made free by the garbage collector. For this reason, it is rarely ever necessary to free the memory manually by using some free_result function.”

I like the fact that I don’t have to litter my code with try-catch blocks and yet I can use them when needed.

Supporting plugins in your application is simple because you can quickly develop a primitive business rule engine based on the capability to invoke functions by name. Then you can specify hooks in your code where functions which have registered (on that hook) are invoked. See WordPress implementation for a trivial example. I think I will write a separate article on this with some code.

Two other niceties are the ability to call functions by name and eval to evaluate any code. Using eval you can define string constants which are actually evaluated and executed at runtime to add functionalities.

There are some downsides too which I had covered earlier, check the links below.

Overall PHP offers a good language and environment for rapid web application development.

Discussion
July 31, 2009: 2:04 pm

I want more info about php . can give me suggestion some other useful article about PHP ?

YOUR VIEW POINT
NAME : (REQUIRED)
MAIL : (REQUIRED)
will not be displayed
WEBSITE : (OPTIONAL)
YOUR
COMMENT :