Create param.php file in protected/config
Yii::app()->params['TEXT_ACTIVE'] = 'Active'; //1 for active
Create param.php file in protected/config
Yii::app()->params['TEXT_ACTIVE'] = 'Active'; //1 for active
The most difficult thing in a big project, is to manage conflicts with files modified by others users. Git can do this work for us.
CSRF é o acrônimo para Cross-site request forgery.
CSRF é um ataque que forca o usuário a executar ações não desejadas numa aplicação Web na qual ele está autenticado.
In this tutorial we will try to save cgridview filter(search) with title etc. basically we want to save two forms data i.e one represents filters and other data about filters like title, description etc. You can define your own structure for filter saving table here are some basic steps
namespace app\components;
首先我们需要下载好Yii tinymce扩展,放入你的extensions目录下,
Example settings when using Gettext for i18n.
When you are handling so many projects and those projects are saved in different repository locations, you may find it very difficult to keep track all the versions and revisions manually and it will be much harder if you are developing in multiple repository branches.
I wanted to customize the CJuiAutoComplete, so that it displays a thumb image before the label like the one shown in the following image:
In this post I am going to describe a solution to make your yii-based web application safe from illegal content injections.
You may find this usefull when you discover your CGridView lost the selection after an update or after a page change, nicely i have build a new extension to cover this problem in a very easy way.
Um aspecto do design da interface de usuário tem a ver com a coerência do design e da utilização das cores entre os diferentes componentes da interface do usuário utilizada.
pagoda box is very useful tool for a programmer to test their php app online so its very useful one. For deploying code pagodabox use git command
Followings are the simple steps to put an analogue clock widget on your skeleton application that is just generated by yiic.
}
`
V. The Order model would start with:
class Order extends CActiveRecord
{
const STATUS_INITIATED = 1;
const STATUS_CANCELED = 2;
const STATUS_EXPIRED = 3;
const STATUS_PAID = 4;
public $statuses = array(
self::STATUS_INITIATED => 'Initiated',
self::STATUS_CANCELED => 'Canceled',
self::STATUS_EXPIRED => 'Expired',
self::STATUS_PAID => 'Paid',
);
// more cod...
In this wiki I will show how to copy a schema from a database to another one
$this->render('index', array(
'dataProvider' => $dataProvider,
));
`
Translation from .txt file Note:
Sometime, in a many-to-many relation, you need to retrieve AR that aren't linked. In practice, AR with null value in the join table. So you implements a criteria like this :
public function scopeUnused( $useAnd = true )
{
$join = " left outer join composed_by j on t.ID = j.ID ";
$condition = ' j.ID Is Null';