Wiki

Sorted by ratingX
Displaying 161-170 of 704 result(s).

Customizing Yii's formatting rules (extending CFormatter)

Created 3 years ago by HaenselTips0 comments – viewed 13,190 times – ( +14 ) – version 1.1
CFormatter is one of Yii's core components and used to format values displayed in widgets like CGridView or CDetailView. All classic formats like numbers, text, urls or datetime are supported but you may have to use a formatting rule that isn't built in. Let's say we want to display arrays of strings (like tags associated with a product model). When using CDetailView we would usually make use of PHPs implode function to create a simple string value of all values in the $product->tags array.

Kickstart development with Yii-App

Created about a year ago by Chris83How-tos24 comments – viewed 23,248 times – ( +21 / -1 ) – version 1.1
I recently created a project called Yii-App on GitHub to kickstart my development of smaller Yii applications. The main goal of the project is to provide a ready-to-use application template that includes my bootstrap extension and many other useful extensions. After reading this article you will be able to use this project as a starting point for all of your Yii projects.

Adding search to Yii blog example (using Zend Lucene)

Created 3 years ago by dckurushinTutorials21 comments – viewed 59,057 times – ( +33 / -3 ) – version 1.1
For this tutorial I will add a search to the blog demo. The search would be based on Zend Lucene.

How to translate and do the translations the easy way

Created 3 years ago by Roman SolomatinHow-tos3 comments – viewed 46,166 times – ( +27 / -2 ) – version 1.1
I wanted to keep all the I18N related translations in separate files, so that I would not need to modify the view files or the model files every time I need to update or fix the translations of application's source language.
tags: i18n

Relational Query - Lazy Loading and Eager Loading / with and together

Created about a year ago by softarkTutorials9 comments – viewed 18,016 times – ( +13 ) – version 1.1
It's well known that there are Lazy Loading approach and Eager Loading approach in the relational query. But it's important to note that you should distinguish 2 different modes in the Eager Loading in Yii 1.1.x.

Simplified meta tags

Created 4 years ago by Y!!Tutorials4 comments – viewed 30,478 times – ( +13 ) – version 1.1
If we want to set meta tags on a per page (controller-action) basis, we may use the clientScript application component.

Getting nulls from database instead of empty strings

Created 3 years ago by samdarkTips2 comments – viewed 9,204 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

YiiBooster: How to implement files and images upload on TbRedactor Widget

Created about a year ago by Antonio RamirezHow-tos3 comments – viewed 18,691 times – ( +13 ) – version 1.1
I have been requested to provide a tutorial on how to use the file upload feature of the TbRedactor widget, and even though I am no longer supporting the library due that the work belongs to Clevertech, I feel that I owe that to the Yii developers. So, here is the  tutorial.

Display a nice exception message on ajax requests

Created 3 years ago by Maurizio Domba CerinTips3 comments – viewed 26,673 times – ( +13 ) – version 1.1
When an exception is thrown in our code like
tags: error, exception

Filter & Sort by calculated/related fields in GridView Yii 2.0

Created 8 months ago by Kartik VTutorials19 comments – viewed 15,872 times – ( +34 / -4 ) – version 2.0
This wiki explains how to add calculated fields into your Yii Framework 2.0 gridview with filtering and sorting.