For those who feel, the Controller->accessRules() or RBAC (Role-Based Access Control) is too complicated or doesn't want the username(s) to be hard-coded in accessRules(), here is a very simple, easy-to-implement solution.
For those who feel, the Controller->accessRules() or RBAC (Role-Based Access Control) is too complicated or doesn't want the username(s) to be hard-coded in accessRules(), here is a very simple, easy-to-implement solution.
In this article, we introduce a set of CSS naming conventions that we have applied in several big projects and achieved success. The goal of these naming conventions is to eliminate the possibility of naming conflicts, facilitate debugging and maintenance, and to simplify the naming process.
To start with you need to download the latest stable release of CKeditor. Extract the downloaded file and place the ckeditor/ folder in your applications webroot directory. (beside "protected" and "css" and other directories)
This is a tutorial for how to auto set model values without any code.
Todos los que hemos empezado a utilizar Yii para crear aplicaciones Web, nos hemos dado de bruces cuando hemos intentado poner a funcionar el RBAC (acceso de control basado en roles).
Many Yii users ask how to create helper classes and functions, and though there are numerous approaches spread out among the forum and wiki articles, this Tutorial tries to bring it all together in one place.
In this wiki I will show you how to save/update a model with many related model For example: How to set a product to multiple categories only in one post form ?
Simple Yii Script for performing CRUD operations:
In this wiki I will show how to display data from two tables in Bootstrap TbGridView using dataProvider.
Hi Friends, In this tutorial I write a code display dependent drop-down value using ajax call.
This page assumes that you have installed Wampserver on your MS Windows computer.
For a complete sample Nginx+PHP-FPM config, view this how-to: Nginx & PHP-FPM
This is the first real problem that I encountered using Yii, trying to make a Model input repeatable in the form, validate and save them.
One of the common tasks the web application might be required to perform, especially the app using some kind of a CMS, is to save the history of data changes. Your client for sure will want the answer to this simple question - If I mess this up or delete by accident can we bring it back? Well, DB backup is one thing and quick recovery is another - let's talk about latter one.
This method was inspirated on the excellent text about different environments available at http://www.yiiframework.com/doc/cookbook/32/
During development, it's often very handy to have SQL logging and profiling.
For each column of the CGridView, we can specify name
, value
, htmlOptions
, cssClassExpression
etc. In the declarations of the attributes value
and cssClassExpression
we can use the "special" variable $data
, for example like this: 'value'=>'$data->author->username',
.
Now we might want to use $data
in the declaration of the `...
In this article you will find Yii framework extensions enabling you to add various charts/print out buttons etc. to your webapp.
It is a common case coders often come accross. For example the purpose of these checkbox is to mark records to be deleted
This is a tutorial to work with radioButtonList which will handle enum datatype. Form design and validation both are detailed here.