How to upgrade Yii 1.x to Yii 2.0

How to upgrade Yii 1.x to the latest version of Yii 2.0? Am I using ubuntu OS, Process to upgrade my old Yii to the new version of Yii version 2.0?

+6
source share
1 answer

The Yii2 manual has excellent documentation in this regard; see Update from v1

I recently ported several moderately complex applications from Yii 1.x to Yii 2.0. There are two ways around this: either you can run Yii 1.x and Yii 2 at the same time as using-yii-2-with-yii-1 . Then move the piece in pieces, while possible, it was quite a bit of pain, like trying to restore the second floor while living on the third.

Alternatively, you can rewrite the entire application from the bottom up with the same functionality, I believe that it is much more efficient, significant code can be reused with only minor changes, which also makes it possible to customize the design without changing the functionality.

It is important to ensure that the open API (i.e. interface / interface / functionality) remains unchanged. It is always tempting to update functionality or change functions during rewriting, however, if you adhere to strict redefinition of everything for Yii2, then consider changing your API, your migration will be smoother.

+16
source

Source: https://habr.com/ru/post/976136/


All Articles