Wiki

Articles in category "tutorials", sorted by ratingX
Displaying 51-60 of 255 result(s).

Displaying, sorting and filtering HasMany & ManyMany relations in CGridView

Created 5 years ago by yJeroenTutorials8 comments – viewed 60,888 times – ( +21 / -1 ) – version 1.1
This tutorial gives you multiple options of how to fully implement showing, sorting and filtering related data in gridviews.

Clean JavaScript code in your views

Created 4 years ago by nineinchnickTutorials6 comments – viewed 31,707 times – ( +20 / -1 ) – version all
This tutorial presents a way of separating JS code from views and passing to it values from PHP.

Using the configuration file, explain what can be configured.

Created 7 years ago by atrandafirTutorials0 comments – viewed 66,812 times – ( +20 / -1 ) – version 1.1
The purpose of this post is to let anyone quickly find how to accomplish a configuration task, and list here all the posibilities of the config.php file and also link to pages that explain how is each thing implemented.

Theming your Zii Widgets

Created 7 years ago by Luis Lobo BorobiaTutorials16 comments – viewed 53,164 times – ( +20 / -1 ) – version 1.1
One aspect of User Interface Design has to do with the coherence of the design and the use of the colors between the different User Interface Components used.

Filter & Sort by Summary Data in GridView Yii 2.0

Created 3 years ago by Kartik VTutorials7 comments – viewed 46,174 times – ( +40 / -5 ) – version 2.0
This wiki explains how to add summary data from related models into your Yii Framework 2.0 gridview with filtering and sorting by the summary columns.

Drills : Search by a HAS_MANY relation in Yii 2.0

Created 3 years ago by softarkTutorials4 comments – viewed 54,801 times – ( +19 / -1 ) – version 2.0
This article tries to describe the practical techniques of searching by a HAS_MANY relation using ActiveRecord of Yii 2.0.

How to display static pages in Yii?

Created 8 years ago by qiangTutorials2 comments – viewed 63,778 times – ( +19 / -1 ) – version 1.1
In a Web application, we often need to display pages like "about this site", "legal information", whose content are mostly static. There are several approaches to deal with this kind of pages.
tags: static pages

How to store array/widget configuration to the database with config validation rules

Created 3 years ago by Kartik VTutorials0 comments – viewed 8,128 times – ( +39 / -5 ) – version 2.0
You may have scenarios, where you want to store a specific array configuration to the database. A classic example could be saving Yii widget configuration to the database and then retrieving it at runtime, with dynamic parameters set. This wiki discusses one of the approaches to do this. Let's consider you have something like the NavBar configuration below to store in the db:

Using your own forked version of extensions with composer

Created 3 years ago by Kartik VTutorials3 comments – viewed 11,671 times – ( +39 / -5 ) – version 2.0
So you want to use a fork of any existing vendor extension with your Yii 2 install and use the fork, instead of original source. This does not need you to push any update or register your package on packagist.org. You are recommended to follow the approach below:

How to customize Yii core messages?

Created 8 years ago by qiangTutorials7 comments – viewed 54,122 times – ( +18 / -1 ) – version 1.1
Yii core messages refer to static text strings in the core Yii framework code which are meant to be displayed to end-users (e.g. core exception messages, default validation error messages). Customization of these core messages is needed in two circumstances: