In our company (small, 4 people) we are going to start using a framework and I’m pushing for Yii. The thing is, with 2.0 (hopefully) coming this year is it smart to use 1.x? I ask because we are going to build a CMS with it and I don’t want to start from scratch then.
Is 2.0 going to be totally different or will it be possible to upgrade with little to no problems?
Official line is that 1.1 backwards compatibility isn’t being taken into consideration. So you will have to update some things most likely. We still heavily use Yii 1.1 and we’ll switch when 2.0 is final but we’re happy to support both. I would say not to wait for 1.1 as 2.0 could still be months away.
End of Maintenance [/i]Dec 31, 2012 (may be extended further if needed)
That “may” doesn’t sound good, big projects need planning. Would you start a big project with a framework that “may” be obsolete in 12 months? I don’t know.
I think we’ll (hopefully) wait a couple of months rather then having to spend the same amount of time upgrading to new version. As ekerazha said, I’d hate to finish a product and then have no updates or bugfixes for it. Plus, I’d like to use shiny new version.
Then again, not having used Yii in the past maybe it would be easier to start with v1.x because there’s more documentation on it.
I don’t know how you feel talking about other frameworks here but there’s also the idea of using Zend. Now, there’s also a news version coming out but personally, I tried the beta and it seems to be all about dependency injection, configuration looks convoluted…but my boss seems to think it would be a good idea because Zend is behind it so we know there’s gonna be support and it won’t be abandoned.
The only reason we’re not using it already is because I will be the one to do bulk of the work so my decision kinda counts
I’m not sure how big changes are planned for 2.0, but conversion from 1.0 to 1.1 was quite smooth. There were a few places which we had to rewrite, but considering amount of changes in framework I expected we’ll spend more time rewriting applications.
Also, remember that even if support for 1.1 will end it is still a mature and well tested software. On the other hand, you may be almost certain there will be at least a few glitches in 2.0 at the beginning.
You’re right and as I see alpha version of 2.0 was pushed to March. Don’t know how long it’ll take to get from there to final, plus We’d probably want to wait for those initial glitches to be fixed.
So it looks like it’ll be a year or so until v2.
I’m leaning more and more towards just using v1. Is “Agile Web Application Development with Yii 1.1 and PHP5” by Jeffrey Winesett a good book get me started?
I bought the book with hope to learn more about TDD in yii and in php - out of luck. In my opinion the title should be "Introduction to Agile Web Application Development with Yii1.1 and PHP5" or similar. If you are familiar with php but not really with MVC then go through all 3 links in tutorials section. If you have any experience with mvc php frameworks then The Definitive Guide to Yii should be enough. Unlike books, tutorials on official yii web page are usually up to date.
While reading the book I had an impression it’s “The Definitive Guide to Yii” with one complete application as example instead of snippets of code in each chapter (which is good). Unfortunately there is “Agile” in the title and author had to put some Agile things as well. TBH I had an impression he googled for TDD, BDD and Agile while writing and when he found something that sounds cool he wrote about that.
He says User Stories yet, he uses UML to describe entities and writes no even single User Story. (Not that UML has no use in Agile programming, but User Stories where created to replace it at least partially ).
He says TDD, yet he tests after writing the code (not always) moreover, he tests auto-generated code which should never be tested in TDD as anything else of the 3rd party origin.
In each Iteration planning he writes about functionality, yet only Models seems to be tested while lot of logic is still in controllers. Functional tests, which would cover controllers and views are only mentioned in one of the first chapters.
If you want a reliable source of TDD then better google for some free tutorials and articles widely available. Best ones I found where written in Java but that doesn’t matter as it’s all about methodology not language.
I’m not saying “Agile Web Application Development with Yii1.1 and PHP5” is bad. I’m saying that in my opinion it is not worth 30$ as it covers only basics of yii and misinforms about Agile Development. There is nothing there you can’t find in tutorials, class reference or wiki on this page.
I like the idea of building the whole application through the course of a book but if You say The Definitive Guide to Yii should be enough I’ll give it a try.
I have some experience with MVC as I worked on two projects in Kohana framework.
The issue you need to take into account is that support for YII will be dropped at the end of the year,so if there are any bugs left at that point in time - they are probably there to stay forever.
Seriously. It is said that support for yii 1.1 will last till end of this year, however it may be extended if needed. I’m pretty sure Yii devs will not stop supporting 1.1 branch until 2.x is production stable and tools helping in migration from 1.1 to 2.x are ready.
What about a comunity-based legacy Yii? Something similar has already been proposed here. The 1.1.x-branch could still be supplied with bugfixes while the core dev team could focus on bringing all the new features to Yii 2.