Wiki

Articles in category "how-tos", sorted by ratingX
Displaying 11-20 of 306 result(s).

Single sign on across multiple subdomains

Created 3 years ago by ianarĂ©How-tos9 comments – viewed 28,045 times – ( +31 ) – version 1.1
This had me stumped for a while so I figured it would be nice to share here to avoid others the grief.

Create your own Validation Rule

Created 3 years ago by nickcvHow-tos11 comments – viewed 120,818 times – ( +72 / -3 ) – version 1.1
Some times the core validation rules provided by Yii won't satisfy all your needs, so you'll need to create your very own validation rule.

Creating a jQueryUI Sortable CGridView

Created 2 years ago by blindMoeHow-tos22 comments – viewed 29,364 times – ( +44 / -1 ) – version 1.1
I have had to do this a couple of times now so I figured I would share it with the community. I am going to keep this short because I really hope that you are familiar with jQueryUI's Sortable class before starting this tutorial.

Searching and Sorting by Count of Related Items in CGridView

Created 2 years ago by softarkHow-tos13 comments – viewed 29,334 times – ( +29 ) – version 1.1
Let's say we have two models and relation between them:

Enforcing "You must agree" requirements in forms

Created 3 years ago by Steve FriedlHow-tos3 comments – viewed 15,681 times – ( +29 ) – version 1.1
Checkboxes have two possible values, true and false, but some applications require that the user select one particular value before proceeding. Examples might be:
tags: validation

Multiple-database support in Yii

Created 3 years ago by Steve FriedlHow-tos14 comments – viewed 65,268 times – ( +28 ) – version 1.1
The customary configuration of a Yii application includes just a single database section in the protected/config/main.php file, but it's easy to extend this to support more than one, tying each Model to one of the databases.
tags: Database

Cookie management in Yii

Created 3 years ago by TrejderHow-tos5 comments – viewed 84,338 times – ( +41 / -1 ) – version 1.1
Cookie management in Yii is easy, but may not be so obvious for the beginners to this framework, so I wrote this simple article to clear some doubts out.

How to use a Widget as an Action Provider

Created 3 years ago by Antonio RamirezHow-tos14 comments – viewed 30,430 times – ( +27 ) – version 1.1
As written on the API docs: An Action Provider Widget is a widget that has declared several actions by using its 'public static function actions()'. After, a Controller can easily import all its declared actions on its 'public function actions()'.
tags: Widgets, CAction

How to use an application behavior to maintain runtime configuration

Created 3 years ago by zaccariaHow-tos3 comments – viewed 23,491 times – ( +27 ) – version 1.1
In this tutorial will be explained a method to manage some configuration runtime. This excellent tutorial follows a similar approach, but requires to write a masterclass which all controllers are supposed to extend, following this wiki you can achieve the same by only editing the configuration.

X-Sendfile - serve large static files efficiently from web applications

Created 3 years ago by Maurizio Domba CerinHow-tos5 comments – viewed 39,213 times – ( +26 ) – version 1.1
Normally when we want users to download a file, that file is put in a folder under the web application root and the web server does the rest.