Wiki

Articles in category "tutorials", sorted by ratingX
Displaying 41-50 of 238 result(s).

Setting and maintaining the language in Application (i18n)

Created 5 years ago by olafureTutorials12 comments – viewed 83,741 times – ( +23 ) – version 1.1
As seen in this post, Yii doesn't enforce how language is set and maintained within the session.
tags: i18n, translation

Impersonate Users within Yii Framework

Created 4 years ago by WoilTutorials5 comments – viewed 13,426 times – ( +22 ) – version 1.1
For some applications it can be advantageous for administration reasons to allow site administrators to login as other users. This is sometimes called user impersonation or "becoming that user".

Display an AJAX tree from your DB using CTreeView

Created 4 years ago by Fran├žois GannazTutorials10 comments – viewed 49,076 times – ( +21 ) – version 1.1
This example uses a MySQL DB with a table named tree with the fields id, name, and parent_id. The parent_id will be NULL for root elements. The SQL is kept simple (no autoinc, no FK, etc).
tags: AJAX, CTreeView

Clean JavaScript code in your views

Created about a year ago by nineinchnickTutorials6 comments – viewed 19,214 times – ( +20 ) – version all
This tutorial presents a way of separating JS code from views and passing to it values from PHP.

Using the configuration file, explain what can be configured.

Created 5 years ago by atrandafirTutorials0 comments – viewed 51,345 times – ( +20 ) – version 1.1
The purpose of this post is to let anyone quickly find how to accomplish a configuration task, and list here all the posibilities of the config.php file and also link to pages that explain how is each thing implemented.

Simple RBAC

Created 2 years ago by hasanaviTutorials17 comments – viewed 70,868 times – ( +47 / -3 ) – version 1.1
If you need simple Role based access control without the long RBAC process then this article is just for you. Lets jump to the point.

How to log changes of ActiveRecords?

Created 6 years ago by pfthTutorials7 comments – viewed 36,250 times – ( +38 / -2 ) – version 1.1
A simple and effective way to keep track what your users are doing within your application is to log their activities related to database modifications. You can log whenever a record was inserted, changed or deleted, and also when and by which user this was done. For a CActiveRecord Model you could use a behavior for this purpose. This way you will be able to add log functionality to ActiveRecords very easily.
tags: Logging

How to display static pages in Yii?

Created 5 years ago by qiangTutorials2 comments – viewed 50,039 times – ( +19 ) – version 1.1
In a Web application, we often need to display pages like "about this site", "legal information", whose content are mostly static. There are several approaches to deal with this kind of pages.
tags: static pages

Theming your Zii Widgets

Created 4 years ago by Luis Lobo BorobiaTutorials16 comments – viewed 44,915 times – ( +19 ) – version 1.1
One aspect of User Interface Design has to do with the coherence of the design and the use of the colors between the different User Interface Components used.

Displaying, sorting and filtering HasMany & ManyMany relations in CGridView

Created 2 years ago by yJeroenTutorials8 comments – viewed 46,273 times – ( +19 ) – version 1.1
This tutorial gives you multiple options of how to fully implement showing, sorting and filtering related data in gridviews.