![]() |
10 abnormalities in CodeIgniter that everyone should know - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: 10 abnormalities in CodeIgniter that everyone should know (/showthread.php?tid=6866) |
10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-17-2008 [eluser]jbowman[/eluser] CI doesn't fit the exact bill of being an object oriented mvc framework. It's true. In fact, I figured this out a while ago and decided to go try Zend, Cake, Symfony, and looked at some non PHP frameworks like Django and Grails... I'm back to using CI and mixing in some of the Zend Framework modules. Why? Because in the end I can get the job done quicker using CI, and it's structured enough that with some basic discipline I can maintain the code very well. The rest were too complicated for their own good, or required learning languages like java and python which I'm just not familiar enough with. CI has it's flaws. It probably is too loose. But, for a lot of us, it really has turned out to be the most productive way. In the end, productivity is the reason you choose a framework. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-23-2008 [eluser]Gordaen[/eluser] I came across this thread while looking for something else, but it sparked my interest... [quote author="Buda" date="1205560725"]I spent 3 months fixing CI bugs and re-designing the entire architecture of the framework. I was quite shocked to find out so many abnormalities and design errors.[/quote] CI Bugs? Which bugs? [quote author="Buda" date="1205560725"]1. 90% of the system is written in PHP 4, a deprecated version of the language.[/quote] This was initially one of the reasons I was skeptical about going forward with CI, but I understand and respect the decision to stay with PHP4. I'll be happy when we can all move on. [quote author="Buda" date="1205560725"]2. The framework doesn't have a Front Controller. Strangely, the application controller becomes the Front Controller, this means that the framework can only load one controller at a time (per request).[/quote] I'm actually really curious to hear a real-world scenario in which you would have a front controller load multiple other controllers. I haven't come across a situation where that's been necessary. [quote author="Buda" date="1205560725"]7. Circular reference: When the Front Controller (App. Controller) loads a model, the framework assigns to the model all the object properties of the Front Controller. This is the most obscure behaviour I found in CI.[/quote] This makes coding for the framework a lot more consistent. *shrugs* [quote author="Buda" date="1205560725"]8. The router.php file contains an array that uses the keys to store data and define regular expressions. If you define 100 elements, the Router class will loop through the entire array, extract the keys and execute 100 regular expressions.[/quote] If there's a literal match, it's done instantly. Otherwise, yeah, it goes through all of them, just as you would expect it to. Is there a better method? Most frameworks use regular expressions for URI mapping, including Django. When it comes down to it, I've found CI to be the best framework for down & dirty coding and for small to medium projects. Anything massive usually entails using symfony or django, but I prefer CI any time it makes sense. Coding for CI is easy and very clear, from my perspective, and it has an excellent user guide that's broken up into logical chunks. It doesn't do everything, nor does it do everything perfectly, but I have enjoyed using it much more than any other framework. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]dsims[/eluser] this post is for buda, I actually just registered for this forum because of this post. If it wasn't for CI you wouldn't even have a basis for your post and your boss wouldn't have a basis for the code that he "owns". It kills me that people like you take someone else's code, modifies it, will not release your modifications and now claims that someone owns the code. Your boss owns the code? How can someone own something that is open source? Who's your boss bill gates? are you trying to make up for something that happened in your childhood and how does posting that you found 10 things you don't like make you feel? You my friend are a vulture, flying high looking for free things. If this code was licensed differently you would then be in a legal problem. If you use open source code then you are lacking the ethics of the open-source community. I found 20 things wrong with your code and I am looking for your forum to post what I found but I cannot tell how to fix them because my boss owns my code. I am sure you would feel different in that situation. Plus the even thought that you do not release your modifications gives me hope that someone will crack your bosses "own special framework", because maybe, if you can wrap your narcissistic mind around this, the more people who look at your work the more secure it would be. You're only human and you shouldn't think otherwise. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]matthewr[/eluser] Hmm... In my opinion, if you don't like it don't use it. There's really no One framework that will work for everybody. Some people like Cake, some people like CI and other like Kohana. I guess it's really just up to what we need and like. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]Jay Turley[/eluser] I'm actually just trying to clarify something. John Fuller wrote a post snarking on pygon ("Pygon, I am glad you figured out the forum.") But I think buda is actually the one with all the complaints about CI. o_O As for me, I believe that there comes a time in every programmer's life when they learn to rise above flame wars and pointless carping and realize that everything is just a tool, and that most of those tools work fantastically *in thier niche*. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]webthink[/eluser] It's a shame the thread has degenerated into this. Unfortunately it's mostly the supporters of CI that have become offended and lashed out. I was hoping it was going to be a real discussion concerning some of CI's shortcomings and how future versions of CI might compensate. I love codeIgniter but I'd love it even more if it addressed some of the points contained in the original message. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]dsims[/eluser] I just get angry when wise arses make posts like this instead of PMing someone like the admins instead. I need to tell everyone what I think is wrong with your program because I will feel better about myself BS. be a little more couth about a situation. In a way he made money off an open source project. I would think that if an open source project helped make you money you would share the results out of respect. But obviously if you have to brag about what you found and fixed without showing source than the same level of respect will be shown back to the individual. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]Jay Turley[/eluser] [quote author="Buda" date="1205560725"]Hi everyone. I was hired by a company to refactor one of their main systems built on top of CI. I spent 3 months fixing CI bugs and re-designing the entire architecture of the framework. I was quite shocked to find out so many abnormalities and design errors.[/quote] I'm actually curious about several things: 1. What version of CI was the original application using? 2. Do you have a list of bugs that you fixed? If so, have you contributed them to the CI bug database so that at some point they could be incorporated into CI Core? If not, why not? Simply stating that they are "proprietary code" is pretty weak. 3. What is your redesigned framework like? How does it operate? How does it compare to other frameworks? Why would you spent time rearchitecting a framework instead of simply choosing another or working within the constraints of the existing one? Just curious, as one developer to another. Thanks! 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]wiredesignz[/eluser] @dsims: There's little point in getting emotional over this. If the OP actually had any idea how to make CI better he could have posted some solutions rather than a bunch of criticisms. Its easy to be critical of other peoples success. 10 abnormalities in CodeIgniter that everyone should know - El Forum - 03-24-2008 [eluser]wiredesignz[/eluser] I'll go one step further and make the OP an offer. If he posts his theoretical improvements (no code is necessary) for any of these percieved issues I will recode them for the whole community to use. |