O'Reilly logo

Web Application Development with Yii 2 and PHP by Jeffrey Winesett, Mark Safronov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Themes

One of the interesting things built into the rendering system of Yii 2 is the support for themes. Together with the amazingly versatile asset bundle system, Yii 2 gives another level of control over the appearance of the web application under maintenance.

The definition of a theme from the official documentation and DocBlock in the comments is probably the best explanation of this concept ever. Here it is:

A theme is a directory of view and layout files. Each file of the theme overrides corresponding file of an application when rendered. A single application may use multiple themes and each may provide totally different experience. At any time only one theme can be active.

The crucial part is that a theme is a separate set of view files that ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required