Wiki articles

Showing 241-260 of 651 items.

How to Enhance a CGridView

Created 11 years ago by bluyell, updated 11 years ago by CeBe.

by: Christian Salazar (bluyell, @salazachris74, christiansalazarh@gmail.com)

2 0
5 followers
Viewed: 12 734 times
Version: 1.1
Category: How-tos

Select2 Infinite Scroll With Remote Data in Yii

Created 11 years ago by IsraelAma, updated 11 years ago by CeBe.

I was able to set up the infinite scroll of select2 in Yii. I am glad to share it with you. The demo and source code can be found here. However, select2 for Yii can be found here which uses a widget.

3 0
5 followers
Viewed: 23 244 times
Version: 1.1
Category: How-tos

Localized version of CFormatter

Created 12 years ago by marcovtwout, updated 11 years ago by marcovtwout.

To replace the application component 'format', which is registered by CApplication by default, you can put this in your application 'components' config:

2 0
5 followers
Viewed: 11 046 times
Version: 1.1
Category: How-tos

Using CJuiDatePicker for CGridView filter

Created 13 years ago by softark, updated 11 years ago by Kostas Apazidis (KonApaz).

We can use a CJuiDatePicker for a CGridView inline filter.

19 0
31 followers
Viewed: 65 350 times
Version: 1.1
Category: How-tos

Installing Yii Users and Rights to Newly Created Yii app

Created 12 years ago by Rajith R, updated 11 years ago by Rajith R.

After creating an yii app . we need to implement permission, Authentication and Authorization .so the best way is to use the Yii users and Rights modules.

11 1
40 followers
Viewed: 110 352 times
Version: 1.1
Category: Tutorials

Syncing sessions between Yii and KCFinder

Created 12 years ago by Thanasis Fotis, updated 11 years ago by Boaz.

>Info: As KCFinder's documentation mentions, if your application (Yii in our case) session handling is using the PHP environment configuration - meaning no change in session handling at all, then no change is needed also on KCFinder side to be able to use this session and thus have this simple interface between your Yii webapp and KCFinder. If t...

1 0
6 followers
Viewed: 17 480 times
Version: 1.1
Category: How-tos

Add information to Yii::app()->user by extending CWebUser (better version)

Created 14 years ago by emix, updated 11 years ago by Anas AbuDayah.

I found a better solution.

5 0
10 followers
Viewed: 51 302 times
Version: 1.1
Category: Tutorials
Tags: rbac, user, Yii

Implementing a User Level Access System

Created 14 years ago by Antonio Ramirez, updated 11 years ago by Phil Loaiza.

Please note that this article is a simple example and good security should be taken into account when we play with authentication systems.

27 0
37 followers
Viewed: 73 316 times
Version: 1.1
Category: Tutorials

Configuring controller access rules to default-deny

Created 14 years ago by Steve Friedl, updated 11 years ago by nsanden.

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
    }

11 0
12 followers
Viewed: 141 196 times
Version: 1.1
Category: How-tos

1:n relations sometimes require CDbCriteria.together

Created 13 years ago by fsb, updated 11 years ago by fsb.

There are situations in which Active Record will generate nonsense queries from what a nieve Yii user might think is reasonable code. One such situation is a CActiveDataProvider using CDbCriteria to get data from parent and 1:n child table with a condition on the child table.

15 0
12 followers
Viewed: 52 864 times
Version: 1.1
Category: Tips

Getting the Most out of APC for Yii

Created 13 years ago by Da:Sourcerer, updated 11 years ago by Da:Sourcerer.

In addition to the opcode cache, APC can also serve as a user cache for Yii via [CApcCache]. It should be noted that this will make APC's memory needs less predictable.

15 0
19 followers
Viewed: 52 612 times
Version: 1.1
Category: How-tos
Tags: apc, caching

Dynamic Sidebar using CClipWidget

Created 14 years ago by Sheldmandu, updated 11 years ago by Cozumel.

There are a couple of ways to achieve this, but the first is preferred.

18 0
18 followers
Viewed: 55 229 times
Version: 1.1
Category: How-tos

How to use ldap in UserIdentity for authentication

Created 15 years ago by BeerSerc, updated 11 years ago by Navarr.

Yii does not have an LDAP class itself, but its very easy to implement LDAP in the stock UserIdentity class.

11 0
18 followers
Viewed: 98 932 times
Version: 1.1
Category: Tutorials

Drop down list with enum values for column of type ENUM >+> incorporate into giix

Created 13 years ago by c@cba, updated 11 years ago by nsanden.

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](...

10 0
11 followers
Viewed: 53 411 times
Version: 1.1
Category: How-tos

jQuery UI Datepicker

Created 12 years ago by softark, updated 11 years ago by Shahcheraghean.

We all love the convenient gadget, namely jQuery UI Datepicker as an input element for date. Yii supports it as CJuiDatePicker. Let's see how to use it.

5 0
12 followers
Viewed: 99 014 times
Version: 1.1
Category: How-tos

Adding a date range search for CGridView the easy way

Created 12 years ago by mikewalen, updated 11 years ago by mikewalen.
  1. Create an Active Record Behavior that builds the criteria for the search() method and attach it to your model
  2. Modify the search() method of the model to merge the behavior's criteria in with the rest of the searchable attributes
  3. Modify the _search form view to add the date range inputs
6 0
11 followers
Viewed: 43 609 times
Version: 1.1
Category: Tips

Catching bounce messages (NDR) and piping them to a Yii command

Created 12 years ago by bennouna, updated 11 years ago by bennouna.

But in the supposedly small share of webapps that don't ask users to activate their accounts, you can end up with a number of bounce messages and non-accessible active accounts.

1 0
7 followers
Viewed: 20 401 times
Version: 1.1
Category: Tutorials

Real-time display of server push data using Server-Sent Events (SSE)

Created 13 years ago by bennouna, updated 11 years ago by bennouna.

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.

9 0
17 followers
Viewed: 65 471 times
Version: 1.1
Category: How-tos

defaultScope

Created 12 years ago by Gerhard Liebenberg, updated 11 years ago by Gerhard Liebenberg.

This example includes a composite condition as well as an empty condition - as if you bypass or disable defaultScope without using resetScope().

3 0
5 followers
Viewed: 34 262 times
Version: 1.1
Category: How-tos

The MrFisk IRC Bot

Created 12 years ago by rAWTAZ, updated 11 years ago by rAWTAZ.

MrFisk is a sleek little bot hanging out in the official #yii IRC channel on freenode, meant to serve Yii users with documentation lookups and other things. This document intends to provide a summary of what MrFisk can do for you and how to use his fin^H^Heatures.

6 0
7 followers
Viewed: 37 530 times
Version: 1.1
Category: Others
Tags: bot, IRC, MrFisk, YiiBot