Beginning Yii
4.0 (11 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
156 students enrolled
Wishlisted Wishlist

Please confirm that you want to add Beginning Yii to your Wishlist.

Add to Wishlist

Beginning Yii

Fast track your web application development by harnessing the power of the Yii PHP framework
4.0 (11 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
156 students enrolled
Created by Packt Publishing
Last updated 9/2014
Current price: $12 Original price: $85 Discount: 86% off
3 days left at this price!
30-Day Money-Back Guarantee
  • 2.5 hours on-demand video
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion

Training 5 or more people?

Get your team access to Udemy's top 2,000 courses anytime, anywhere.

Try Udemy for Business
What Will I Learn?
  • Beginning Yii is a step-by-step tutorial for developing web applications using Yii. This video course follows the iterative approach to software development while developing a photo gallery website.
View Curriculum
  • Beginning Yii is a step-by-step tutorial for developing web applications using Yii. This video course follows the iterative approach to software development while developing a photo gallery website.

Starting with the basics of installing and configuring Yii, you will learn how to use the Yii application generator to build your first fully working application with just one command. You will then move on to a step-by-step progression to tailoring this to your requirements by including database access methods and manipulating queries as well as using sub-forms and third-party plugins. This course also covers how to use the fully integrated auto-testing tools such as PHPUnit and Selenium, uploading and crunching images, using themes, user security and authentication, debugging and logging, and finally how to configure your application for deployment.

By the end of Beginning Yii, you will be fully conversant with the Yii framework, and you will be able to confidently build applications.

About the Author

Chris Backhouse is an independent web developer with 30 years of experience in Software Development. Over the past 3 years, he has specialized in optimising businesses by building customized web applications based on LAMP technologies and PHP frameworks such as Yii. He has been using web platforms for more than 10 years.

Previously, Chris provided independent consultancy to international businesses around Europe. His particular expertise lay in the management of introducing advanced technologies into the system development work place and the creation and maintenance of the processes involved. Companies such as Cisco Inc, Hyder plc, and Microsoft UK have benefited in these areas.

Who is the target audience?
  • If you are a PHP developer, either with or without previous framework experience, and you have an interest to learn Yii and to rapidly develop modern, sophisticated web applications, then this course is for you. No prior knowledge of Yii is expected.
Compare to Other Yii Framework Courses
Curriculum For This Course
41 Lectures
Exploring Yii
5 Lectures 16:13

In this video, you’ll be introduced to the topics that will be covered in the course.

Introduction to the Course

Understand how a Framework is an architectural collection of tools

What Is a Framework?

MVC architecture is important because it produces a structured and an easily maintainable code.

What Is an MVC

To better understand the flow of information and which component is responsible for what, we’ll take a look at the MVC request routing.

MVC Request Routing

What makes Yii so popular?

Introducing Yii
Getting Started with Yii
5 Lectures 19:13

You will need to have these items installed and running before you can start development. Ensuring that your versions are current and up to date will mean that you are less likely to have incompatibility problems. You must be running PHP 5.3 or later.

Getting Started with Yii

Using Yii to generate the web application builds the skeleton disrectory structure and adds the necessary bootstrap and configuration files. This makes it much quicker and easier to start development.

Generating a Web Application with Yii

Understanding the Yii configuration file and the flexibility it can provide will make both development and deployment of your application much easier.

Configuring Yii

By developing an application such as this, we will be able to meet a broad spectrum of everyday issues, such as specialised validation, url management and image manipulation. We will also see how we can add functionality in layers taking the development from prototype to full application.

Developing a Photo Gallery Application

The code generated by Gii will account for a large percentage of your final code base, thus saving you both time and money in the development lifecycle.

Using Gii to Generate the CRUD Application
Starting Development (Using Our IDE)
6 Lectures 24:32

The CActiveRecord object is Yii's encapsulation of database manipulation, and it provides extensive functions to simplify database queries and updates.

Preview 04:10

The Yii CHtml object provides a rich functionality for generating complex HTML and JavaScript. We will see how to quickly adapt to the autogenerated forms.

Preview 03:45

Integrating server-side and client-side apps can often be complex and messy. We will see how third-party Yii extensions can easily be integrated with our application.

Preview 04:28

In this video, we'll look into adding new columns to the album's data model class, specifying new validation rules and removing unwanted search terms.

Preview 03:40

Understanding the controller processing in a create and update scenario helps you change the create and update forms and manage model validation.

Preview 04:16

Learn how to embed an existing form from one model as a subform in another model by understanding how to query and display data from other models.

Preview 04:13
5 Lectures 18:37

Testing often gets left or forgotten.Understand the benefits of implementing automated testing tools whatever the scale of your development.

Testing Our Application

We will demonstrate how quick and easy it is to set up a testing environment.

Setting Up Our Test Environment

Learn how to produce and run PHPUnit scripts and analyze the results.

Creating a Unit Test to Automate the Testing of Common Tasks

Learn how to automate the action of ensuring that you are always testing with the same data.

Using Fixtures

Automating the functional tests will quickly enable you to retest pages across your application with minimal effort.

Functional Testing with Selenium Server
The Photo Application
5 Lectures 19:52

Extensions can save a huge amount of development effort, so familiarity with the extensions library is beneficial.

Installing Yii Extensions

How to include third-party widgets and customize them to our needs.

Preparing the Forms and Inserting the Uploader Widget

Learn how to process Ajax requests and manage image/binary files using the cUploadedFile class.

Building a Controller Action to Upload and Crunch Our Images

Understanding this powerful tool can simplify your form development.

Understanding the GridView and Customizing It's Layout

Customize the actions available for each row to increase the flexibility of this widget.

Adding Finishing Touches to the Photo Album Management Forms
Themes, Layout and User Access
5 Lectures 20:14

We will learn how theme files override application files, and also how the hierarchy of the views are displayed.

Theming an Application

We will see how we can alter the available navigation items for authenticated and guest users.

Modifying the Default System Layout to Modify the Menus

We will show how the login process manages the relationship between the user authentication and the web user session, and how to customise this process.

User Authentication – The Default Yii Model

We will learn how we can quickly and easily tailor the web user class for our applications.

Extending the Yii User Model to Suit Our Application

We will learn how controller implements access rules, and how we can adapt these to suit our needs. We will also see how we can apply restrictions across multiple access rules using user-defined filters.

Understanding the Yii Security Model
Debugging, Logging and Error Handling in Yii
5 Lectures 24:05

There are occasions when we need to step through our code line by line to find that illusive bug or to trace the value of a variable, and xDebug is the tool for this job.

Using Xdebug to Debug Your Applications in Real Time

Using log routes will enable us to divert the output to different files for different log levels and categories.

Configuring Yii to Use Different Log Routes

SQL debugging and profiling enable us to more accurately analyze and pinpoint bottlenecks and produce more efficient SQL and code.

Profiling SQL queries

Learn to use a tool that will be indispensable in debugging your code.

Installing and Using the Yii Debug Toolbar Extension

Understand how to use error handling to hide system specifics from users and hackers.

Exception Handling in Yii Using the CException and CHttpException classes
Customizing Our Album Interface
5 Lectures 21:29

Understand how using a cross-model functionality demonstrates how an MVC architecture holds the business rules at the model level.

Including Tags -Part 1

We store the tags in a single text field using a comma delimited approach, so we need to present this to users in an understandable and easy-to-use manner. To this end, we will be adding an auto-complete widget to the album/update form.

Including Tags – Part 2 and Using Model Behaviors

Learn how to easily integrate cross-table lookups using relationships and the listData method.

Using Lookups and Dropdown-List Boxes

When we start mixing up models in our processes, it sometimes becomes unclear about where one should add a functionality. Here we will see both, adding an addComment function to the photo model and keeping the comment forms separate.

Adding the Comment Add and Display Forms

In smaller application development teams, it is easier to keep track of the development versus production configuration but even then it is important to be aware of overwriting the production configuration. In a larger system, it becomes imperative to split the configuration file into manageable portions.

Deploying Our Photo Application
About the Instructor
Packt Publishing
3.9 Average rating
8,274 Reviews
59,217 Students
687 Courses
Tech Knowledge in Motion

Packt has been committed to developer learning since 2004. A lot has changed in software since then - but Packt has remained responsive to these changes, continuing to look forward at the trends and tools defining the way we work and live. And how to put them to work.

With an extensive library of content - more than 4000 books and video courses -Packt's mission is to help developers stay relevant in a rapidly changing world. From new web frameworks and programming languages, to cutting edge data analytics, and DevOps, Packt takes software professionals in every field to what's important to them now.

From skills that will help you to develop and future proof your career to immediate solutions to every day tech challenges, Packt is a go-to resource to make you a better, smarter developer.

Packt Udemy courses continue this tradition, bringing you comprehensive yet concise video courses straight from the experts.