Book Image

Yii2 Application Development Solutions - Volume 1 [Video]

By : Andrey Bogdanov, Dmitry Eliseev
Book Image

Yii2 Application Development Solutions - Volume 1 [Video]

By: Andrey Bogdanov, Dmitry Eliseev

Overview of this book

<p><span id="description" class="sugar_field">Yii is a free, open-source web application development framework written in PHP5 that promotes clean DRY design and encourages rapid development. It works to streamline your application development time and helps to ensure an extremely efficient, extensible, and maintainable end product. Being extremely performance optimized, Yii is a perfect choice for any size project. You have full control over the configuration from head-to-toe (presentation-to-persistence) to conform to your enterprise development guidelines. It comes packaged with tools to help test and debug your application and has clear and comprehensive documentation.</span></p> <p><span id="description" class="sugar_field">This video course is a collection of Yii2 videos. Each video is represented as a full and independent item, which showcases solutions from real web-applications. So you can easily reproduce them in your environment and learn Yii2 fast and without tears… In this video, you will get started by learning how to install Yii Framework and about application templates, dependency injection container, and model events. You will also learn how to use the external code and how to update your yii-1.x.x based application to yii2. Then, you will see some handy things about the Yii URL router, controllers, and views. The course then proceeds to discuss the three main methods to work with databases in Yii: Active Record, query builder, and direct SQL queries through DAO. Then we will see the working of Forms in Yii and how to keep the application secure. We will look at creating our own controller filters, preventing XSS, CSRF, and SQL injections, and using role-based access control. Later, you will learn to write RESTful Web Services using Yii2. Finally, the course ends by teaching you to install and use official extensions in your project.</span></p> <p><span id="description" class="sugar_field">This course will show you how to easily get started, configure your environment, and be ready to write web applications efficiently and quickly.</span></p> <h1><span class="sugar_field">Style and Approach</span></h1> <p><span class="sugar_field">The sections of this video are independent and offer a practical approach to Yii development. You can start reading from the section you need most, be it Ajax and jQuery, RESTful Web Services, Database, Active Record, or Official Extensions. <br /></span></p>
Table of Contents (7 chapters)
Chapter 2
Routing, Controllers, and Views
Content Locked
Section 8
Using Flash Messages
Typically, after some kind of action, such as editing a form, a redirect will happen and we need to display a message on the page we want to go to. However, how do we pass it from the current page to the redirect target and clean up afterwards? Flash messages will help us do this. - Understand the importance of flash messages - Add a callback function - Set up an error message that redirects to the index page