While there is a reasonable amount of documentation regarding CForm (form builder) and file uploads seperately, there really is not any coverage of both in combination.
While there is a reasonable amount of documentation regarding CForm (form builder) and file uploads seperately, there really is not any coverage of both in combination.
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.
Let's say you have an internal messaging system in your webapp, and you want to display messages dynamically and real-time to the relevant recipients.
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 say our table 'mug' has a column named 'color' of the type ENUM('red','green','blue').
We want to replace the textfield for the attribute color in the create and update forms of a 'mug' with a drop down list, which has the enum values as options.
The main code was contributed by zaccaria in the forum (see [this post](...
This widget will show a Facebook "like" button and "comments" box together with "tweet" button and "google plusone" button on your page.
I'm developing a website that has an option to look up a car's registration number via SOAP and return additional details such as make, model, colour etc.
Hey guys, I'm hoping other people will find this helpful. Today I went through the process of adding CKEditor to one of my projects, and then integrating KCFinder as the image uploader. It will be used in a CActiveForm, without the use of any crazy weird widgets. All paths are relative, using Yii functions, so this will work no matter where you install. Here it is:
This article tries to explain the steps required in integrating the HybridAuth into Yii directly, without using an extension.
Sometimes the right place to store application data is in a join table. For example, movie viewers either like or don’t like the movies they watched.
This wiki will explain how to include a javascript library in a widget.
Some of you have experienced the need to log some information while doing unit testing, due to the fact that the information given in the summary is just not enough, to know why the test is actually failing. this article focuses on 2 ways to get you logs up and running again.
Occasionally one wishes to set systemwide parameters for an application, such as a contact address for email, an application name, or setting an option that guides major behavior. Yii provides for setting of static parameters in the configuration file, and this article talks about how to do it conveniently.
Starting with the blog tutorial, Yii developers are familiar with the notion of access rules defined in the controller, where the actions are allowed or denied depending on the user's name or role.
class CommentController extends CController {
public function filters()
{
return array( 'accessControl' ); // perform access control for CRUD operations
}
I discovered Twitter Bootstrap almost two years ago. After trying it out for a while I fell in love with it. It didn't take long before I realized that it would be great to write an extension that allowed developers to start using Bootstrap in their Yii projects. One night I sat down and started writing what later became my now popular [bootstrap extension](http://ww...
Yii makes it really easy for all to use their already made objects that automate everything we do. It provides also great power of flexibility and styling but hey, we programmers tend to complicate our lives and push a little more the power of our tools.
This is a simple example that will give you a base for designing a database driven menu system that will use CMenu to be rendered.
This solution requires Yii 1.1.9 or above
Create a folder where to place an Yii app under wordpress folder (mine is "yii')