Wiki

Sorted by viewsX
Displaying 411-420 of 703 result(s).

A Multi-Tenant Strategy using Yii and MySQL

Created 9 months ago by JFReyesHow-tos7 comments – viewed 9,690 times – ( +8 ) – version 1.1
This article describes an implementation of multi-tenancy using Yii and MySQL.

Yii code completion and calltips in Komodo Edit

Created 3 years ago by viterTips1 comment – viewed 9,640 times – ( +6 ) – version 1.1
My favourite editor is Komodo Edit (free and crossplatform) and I use it for my everyday coding work. Just recently I found out how to make it help me to work with Yii. :) So follow these steps:
tags: Komodo Edit

Encapsulate db and module configurations

Created 5 years ago by ricardogranaTutorials3 comments – viewed 9,587 times – ( +7 ) – version 1.1
This method was inspirated on the excellent text about different environments available at http://www.yiiframework.com/doc/cookbook/32/
tags: module

Using Yii with PHP 5.4 built-in webserver instead of Apache

Created 2 years ago by samdarkHow-tos1 comment – viewed 9,400 times – ( +21 ) – version 1.1
Since version 5.4 PHP can work as a simple webserver so you can develop Yii applications without installing Apache. That's how to use it:

Adding 'disabled' to CCheckBoxColumn and support for yiigridview.js

Created about a year ago by Xgamer99Tips3 comments – viewed 9,380 times – ( +1 ) – version 1.1
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 or on the 'select all' checkbox.

How to extend CFormatter, add i18n support to booleanFormat and use it in CDetailView

Created 2 years ago by c@cbaHow-tos3 comments – viewed 9,372 times – ( +9 ) – version 1.1
As you know, the CDetailView widget displays details of a single model. If no formatting is specified, boolean values that are stored in the database as 0 and 1, are represented in the detail view as 0 and 1. If formatted as boolean, they are represented as 'No' and 'Yes'. We want to add i18n support, so that Yes and No appear in the current language.

YII SaaS Multi Tenant application with single database

Created about a year ago by Rajith RTutorials5 comments – viewed 9,209 times – ( +10 / -10 ) – version 1.1
Lots of people are asking how to solve it with YII,We think its difficult with YII. But its easy to solve . There is no database triggers needed . we can simply sove it by extending a class(say "RActiveRecord") from CActiveRecord .Then extend all our model classes from that class.

Getting nulls from database instead of empty strings

Created 3 years ago by samdarkTips2 comments – viewed 9,199 times – ( +13 ) – version 1.1
To get null from database instead of empty strings you need to set up your DB connection as follows:
tags: database, null

Insert a multirow header in CGridView

Created about a year ago by PeppeHow-tos2 comments – viewed 9,161 times – ( +5 ) – version 1.1
The CGridView widget is very useful and customizable, but sometimes you need a little more. One limit I found is to have only one row for headers; yes, you can write each column header in more than one row, but just inside the single cell. I was looking instead for the possibility to use more than one row, with different structure one from the others. This way you can write columns grouping headers, and obtain a nicer view.

Using CListView to display items next to each other (in columns)

Created about a year ago by thyseusTips3 comments – viewed 9,137 times – ( +11 )
When using CListView to display multiple views next to each other, we can use the $index variable inside the viewFile to achieve this. As far as i know there is no extension or out-of-the-box functionality for this, so we need to apply a little hack: