Reputation: 539
There is yii2
which instaled via composer. What specific steps should be taken to connect the additional library library to the current project. Also same question if need connect only simple class.
Upvotes: 1
Views: 673
Reputation: 1713
Composer found at https://getcomposer.org is your best friend while adding new libraries to yii2 framework.
e.g. you would like to add kartik yii2 widgets found at http://demos.krajee.com/ to your yii2 application.
php -v
if it works then fine, if not, that you need to set path variable.
CD
through command prompt php composer.phar require kartik-v/yii2-widgets "*"
To simply connect and using any custom class, follow this guide. http://www.yiiframework.com/wiki/747/write-use-a-custom-component-in-yii2-0/
Yii is mvc framework and it has specific methodology to connect and use with model, view, conntroller. Follow this link to find more http://www.yiiframework.com/doc/guide/1.1/en/basics.mvc
Upvotes: 2
Reputation: 133400
Normally additional libraries (extensions) are provided with commands for installing the necessary software by composer and instructions on how to configure these modules and components in this initial configuration file. In the advanced template (the organizing schema of the most appropriate code for professional projects) is called main.php and is located in the config directory of each appllicazione (frontend, backend) and in common area accessible to entering for shared configurations. . For what regards the addition of classes .. all what is related to the MVC programming pattern is well organized in the appropriate directory, and then the addition of application classes favors this scheme .. The management of classes or related items can be organized easily into components and modules .........
For all of these and much more you can refer to the guide that is also able to illustrate with concrete examples the many features that characterize Yii.
http://www.yiiframework.com/doc-2.0/guide-index.html
http://www.yiiframework.com/doc-2.0/
Upvotes: 0