How to display status image on admin gridview.
How to display status image on admin gridview.
I recently had to have a checkbox column in my grid view that supported the 'disabled' attribute. This was easy enough to do by extending the CCheckBoxColumn. However, I also wanted the checkbox to be selected when clicking on the table's row (supported via CGridView's selectableRows option). I discovered I had to tweak yiigridview.js so that it would not select disabled rows when clicking on it o...
This article shows one of possible ways to implement menu items (as well as links), which displays a progress / wait dialog and are redirecting browser to destination URL in the same time. This is especially useful, for links or routes that are know to be loaded for a prolonged period of time (i.e. getting a lot of data from database).
A short explication on how to extract profile information for PHP on your server using XDebug and KCacheGrind or WinCacheGrind.
Today i want to share with you is "How can we write HTML Code in view files? I am writing this article because many times we can not use CActiveForm to design our form...
Lets say we have 3 modules (customer, user, admin) in an application and we need, separate logins for each module.
This Behaviour helps to view time/date/timestamp/datetime from db to local Date / Time / Date Time format and in local Timezone. And save into db in with db timezone and db format. You only need to include this behaviour in models where need this facility.
To accomplish the task of changing Migration table's name, by default tbl_migration, you need to add the following in your ./protected/config/console.php.
The problem: If you type Yii::app()->user<ctrl+space> code completion didn't work. This solve it.
How to add additional information to a user when using BUM extension?
Stores session data in database and transfer data when session is destroy. Uses for check users online, user's last activity and last ip.
Yesterday I've written a module for myself. Just an experiment. When I was feeling satisfied, I've created a repository on github, and pushed my code. My module and yii are on github. So I'll show you a "new" way to start our yii projects.
There are scenarios when you work with DVCS (like [Mercurial]( http://mercurial.selenic.com/) or [Git]( http://git-scm.com/)) and CDbMessageSource. To my experience keeping the development database and production database in sync can be very...
Sometimes text inside a gridview column is just too long. That's why I figured out a way to make the column smaller while still providing the information.
Let's take the example of the above article to display an email button next to a delete button:
Sometimes we need to create our custom exception and show it to the end user through a friendly way . In this article, I'm showing how to do it using CJuidialog.
Search Models are a very elegant and powerful way to build an Active Data Provider. If you use them a lot, you'll quickly need to use scenarios, which will lead you to a very DRY Controller code.
This behavior will automatically set timestamp fields to the row creation and modification times.
At first, create a class named SmartyRenderer under application/components or any directory you want.