📜 ⬆️ ⬇️

Yii 1.1.6

PHP framework Yii has been updated to version 1.1.6. Update not only corrects errors, but
and adds a lot of new things. What changes have been made?



SQL Query Builder


')
It allows you not to use Active Record and at the same time to write pleasant clear code:

$user = Yii::app()->db->createCommand() ->select('username, password') ->from('tbl_user') ->where('id=:id', array(':id'=>1)) ->queryRow(); 


Read more

Migration support



Migrations help keep the database schema up to date with team development.
The toolkit is implemented as a console utility and can be used as in manual mode,
and for automatic deployment using SVN hooks.

Read more

Yii :: t learned to translate the plural forms of numbers according to the CLDR rules



It looks like this:

 Yii::t('test', '{username} has a cucumber|{username} has {n} cucumbers', array(5, '{username}' => 'samdark')); 


The result is:

  samdark has 5 cucumbers


Read more

Improved error messages



Improved error message can show call parameters, blocks
code for all elements of the trace and looks more nice.

Support for anonymous parameters and global options in console commands



Now you can create console commands that can be configured globally
and use positional anonymous parameters in their actions.

Read more

MVC Guide



A good guide on the principles of MVC . Help developers better understand how to write correctly.
applications on yii.

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


All Articles