- Posted by Tengku Zahasman on April 29th, 2007 filed in Web Programming, PHP, CakePHP, Web App Development
- (14,912 Views)
Even though I have been programming for years, I have never actually fully utilized a web application framework when developing web applications. Part of the reason being that I may be a bit too proud to adopt someone else’s programming structure. I used to believe in my own codes so I always write applications from scratch. That was a big mistake. After I found and studied a great web application framework for PHP since just a few weeks ago, I realized how much time I have wasted all these while and how many headaches I had to go through just to rewrite the same codes and reinvent the wheel all over again.
For those who are new to web application framework, I’ll try to explain it briefly here. Everytime we start writing a web application, there are some basic codes that we need to repetitively write again and again. We had to write the database connection classes for the database access layer, we had to write every objects classes with their basic CRUD methods. Then we had to deal with so many annoying basic issues like Access Control Lists (ACL), data sanitizations, authentications and authorizations, session handlings, and you know… the rest of those stuffs. This same repetitive coding is a waste of time if you keep writing them from scratch. Plus, you can’t be really sure that the structure of your code is secure and lightweight enough to run. Then you started to wonder, “Am I doing this correctly? Is this exactly how everybody does it?” Here’s where an application framework comes in. An application framework is basically a standard programming structure that already pre-defines those repetitive stuffs as well as any other necessary functions so that you can easily and effectively write your web applications in no time.
Let’s see some of the few benefits that I find when using a Web Development Framework:
1. It saves a hell lot of time
Because you don’t need to worry about data sanitizaion, session handling, error handling, and authentication logics anymore (ok maybe just a little bit). Most of these are well taken care of by the framework. No more head scratching. You can start writing functions for your apps straight away without wasting anymore time with those repetitive codings. Double up development process!
2. Organized application structure
Another thing to not worry is about managing your web files and directories. The framework will already have a good skeleton structure to use. No more stuffing PHP files here and there and then realizing at one point that you have messed up with your files’ placings. Business logics can be separated from the interface files. Things get more organized.
3. Flexibility over different platforms
I’m a MYSQL user. If you give me a Postgresql database to use, I’d be scratching my head again if I am to write the application from scratch. Luckily a framework can help me not to waste time studying things that don’t really matter. A few tweaks can ship my application from one platform to another.
4. Secure codes
This is another huge advantage of using a development framework. You can be sure that your application is using good security measurements because the framework takes care of it. No need to worry over those nerd hackers trying to break your application anymore. In fact, I’ve never been truly confident that my application is secure if I write them from scratch. Now that I’m starting to use a framework, I feel much… much better
There are endless other benefits of using a web application framework but to list them all here is crazy. So I’ll let you decide the rest of them. I mainly develop web apps in PHP, so the framework that I’m currently exploring is CakePHP. I’ve looked into other PHP frameworks but so far I guess CakePHP got my attention the most.Tags: cakephp php web app development web application framework