Wiki

Articles in category "tips", sorted by viewsX
Displaying 31-40 of 133 result(s).

Customizing the CMenu Widget

Created about a year ago by mistrybTips1 comment – viewed 21,761 times – ( +1 / -1 )
The CMenu class provides some useful features for generating menus in your web application.

Search method of a model for filters when using dates - unixtimestamp in database

Created 3 years ago by MukkeTips1 comment – viewed 21,497 times – ( +10 ) – version 1.1
I ran into a problem and on irc we worked it out. Since there is a lack on information on filters in genral i thought i'd start sharing all my findings, might be usefull for other people.

Extending common classes to allow better customization

Created 3 years ago by Steve FriedlTips0 comments – viewed 20,686 times – ( +41 ) – version 1.1
The two most commonly-used base classes in most Yii applications are CController and CActiveRecord, each extended to your own particular models and controllers.

An easy way to use escopes and CActiveDataProvider

Created 3 years ago by Rafael GarciaTips8 comments – viewed 20,218 times – ( +1 / -1 ) – version 1.1
Often used scopes to define criteria in our models. This is a very useful feature as it ensures that in any part of application applying the criteria defined by the scope when called it.

Customize CGridView columns directly in your view

Created about a year ago by clapasTips4 comments – viewed 19,017 times – ( +3 / -2 ) – version 1.1
You usually take a model instance passed into your view to provide data to a CGridView in this way:

Using counters with ActiveRecord

Created 2 years ago by davi_alexandreTips8 comments – viewed 18,236 times – ( +14 / -1 ) – version 1.1
Let's say, for example, that you are developing a blog or some kind of CMS and you want to track the number of times each post was viewed (maybe to show a list of the most viewed ones).

Real Time Logging

Created 3 years ago by lucifuriousTips3 comments – viewed 18,095 times – ( +14 ) – version 1.1
I've seen a lot of people asking about the logging facilities in Yii and thought I'd share a nice little class I wrote that provides near real-time logging.

Avoiding duplicate script download when using Ajax calls to render different Views

Created 2 years ago by Antonio RamirezTips5 comments – viewed 17,504 times – ( +12 / -1 ) – version 1.1
I had to partially render two types of views, depending on user selection. Wanted to display a GRID or a LIST style with an event that AJAX'ed new contents and update a layer with them.
tags: tutorial, AJAX, views

Troubleshooting Rights Extension

Created 2 years ago by junxiongTips5 comments – viewed 17,136 times – ( +8 ) – version 1.1
Rights is one of user interface for Yii's Role Base Access Control extension. It is one of most downloaded extensions in Yii's Web.

Yii实战中8个必备常用的扩展,模块和

Created 3 years ago by Darwin WenTips2 comments – viewed 16,876 times – ( +2 / -3 ) – version 1.1
在经过畅K网的实战后,总结一下在Yii的项目中会经常用到的组件和一些基本的使用方法,分享给大家,同时也给自己留个备忘录,下面我以代码加图片说明.
tags: module, Widgets