Feb
27
I promised Derek Allard that I’ll be publishing some examples of how I integrated mootools with Code Igniter, but alas, I have not yet had made the time to just sit down and do it. I promise, Derek, soon!
I just want to add that I have not integrated mootools as an Code Igniter class or library. I should prolly, but here is my reason for not doing it. Two reasons actually:
- I’m too damn lazy… That and deadlines was WHOOSHING by again.
- I like my Javascript seperated from my PHP and Code Igniter classes!
I’ll focus on the second reason, since that one is easier to defend.
Firstly, let me just say once more that it is a matter of preference! I’m not arguing right and wrong here. Simply what I prefer and that can hopefully help you make up your mind if you have similar questions.
If you are going to integrate mootools with Code Igniter, you are going to write PHP that generates Javascript functions/classes. That for me is somewhat against the grain of the whole MVC philosophy. You already seperate your database access from your business logic from your HTML views. Now, you want to write PHP that generates Javascript just to make it easier to implement. What if you need very particular functionality? You will then have to want to stick with extending your PHP library to generate the appropriate Javascript functions. This is perfectly alright, but not always practical, since you might have certain time constraints.
There is of course a number of drawbacks you will need to consider when implementing mootools seperately, but more on that at a later stage.
Maybe I can be convinced that integrating it is better? I don’t know. It just feels more comfortable having it seperate.
technorati tags:codeigniter, mootools, javascript, php
Blogged with Flock
Sharing is caring:These icons link to social bookmarking sites where readers can share and discover new web pages.
Code Igniter, PHP, javascript, mootools Stii
Jan
15
After my “discussion” with devkungfoo about PHP MVC frameworks, I decided to re-develop one of our current projects in Code Igniter. The project was about 60% complete, so I thought it might not be a bad idea since I’m anyway not going to have time playing with CI.
It turns out that it is by FAR the best idea I’ve had so far in 2007! I plonked myself in front of my PC over the weekend and started fooling around, reading the docs and testing it. My first thoughts was I’m biteing off more I can chew at such a late stage. Then this morning I plunged into the project to see how far I can get and how long it will take me to get with this project to get up to date (at least till where I am now).
I’m stoked!!! It took me all of a week’s work (thats how long it took me to do the part I’ve done in Code Igniter) in one day. It is amazing. AMAZING!!!
You guys at Code Igniter are the absolute best! PHP Developers, if you are looking to use a MVC framework (and you SHOULD), then stop looking any further and go with Code Igniter.
For the guys at CI, I’m planning to re-develop a pet project of mine later when time allows, and I’ll give back by doing it tutorial style! Maybe I can even persuade devkungfoo to join in. What do you say Dinesh?
technorati tags:php, softwaredevelopment, mvc, codeigniter
Blogged with Flock
Sharing is caring:These icons link to social bookmarking sites where readers can share and discover new web pages.
Code Igniter, Kick-ass Tools, PHP Stii
Jan
10
I recently commented like a super-cowboy on devkungfoo’s blog. I made the following (stupid|hot-headed) statement:
I’m considering writing my next big project from scratch, steering clear from any frameworks for now.
Believe me if I tell you that its been on my mind for most of my holiday. I should really learn to think before I shoot my mouth off like some MG42 (I’m playing Call of Duty 3
) machine gun!
Let me explain. With the coming of Web 2.0 there has been a lot of focus on MVC (Model-View-Controller) development frameworks. What makes them special is that they follow some very important development principles like the DRY (Don’t Repeat Yourself) principle and they do Database abstraction GOOD! They also encapsulate a lot of standard functions in a “tool library” (if I may call it that) that makes software development quick. Really QUICK. They also separate your data (Models) from your logic (Controller) and your HTML (Views). So all in all, I do not for the life of me know why I made such a comment! MVC’s are great and should be used. To redevelop from scratch, although very novel and brave, is somewhat stupid. Yes, I know I’m contradicting myself something awful, but I’ve been known to do that due to my bloody motormouth.
Last year I spent a lot of time researching a bunch of MVC frameworks. I first of all looked at Ruby on Rails which is arguably one of the best frameworks out there. The cons of this frameworks for me was:
- Its new and most ISP’s do not support it. Our ISP said the only way they’ll host it is if we farm our own server at them and maintain/install it ourselves. Now that seemed like a fun and interesting prospect at the time, but time was the major constraint!
- The other point is that it is a new language which I needed to learn. Also a time constraint issue, although they have a GREAT thing called InstantRails for Windows that do the entire setup process for you! So I have played with it and would definitely look at doing some projects in future using RoR. Ruby is a wonderful language!
Another great MVC framework written in Python and well worth while checking out if you can develop in Python is Django. But the same goes for Django that goes for Ruby on Rails.
I then decided to look at what is available in PHP since I’m proficient in it. Was I pleasantly surprised! There are hundreds of frameworks! All flavors and for all versions of PHP. Lovely! I still found that there is quite a learning curve involved in these PHP frameworks and although I know PHP like the back of my hand, I have to learn how to implement things utilizing the framework to its full potential!
I ended up singling out two frameworks: CakePHP and Code Igniter.
CakePHP is considered the Ruby on Rails of PHP. A great and extremely powerful framework it is, but I found it a bit clunky and big and in some instances simply overkill!
Code Igniter on the other hand is extremely lightweight and flexible and a whole lot simpler to learn. It lacks in certain aspects as at the time it had no AJAX support, but including AJAX was not a big issue as it was easy enough to do.
So, out of the frameworks, Code Igniter is the one to use for small to medium sized projects.

technorati tags:softwaredevelopment, programming, mvc, frameworks, php, rubyonrails, ror, python, django, webdevelopment
Blogged with Flock
Sharing is caring:These icons link to social bookmarking sites where readers can share and discover new web pages.
Code Igniter, PHP, Python, Ruby (on Rails), web development Stii