Articles in category "how-tos", sorted by ratingX
Displaying 141-150 of 355 result(s).

Using a CDbDataReader (sql query result) in a zii widget (such as CGridView or CListView)

Created 6 years ago by Revelis Luc BonninHow-tos2 comments – viewed 29,014 times – ( +9 / -2 ) – version 1.1
If in your application you have to proceed to a complex SQL query that is not associated to a model, you will use CDbDataReader like it is described in the Yii documentation. An example could be

Show captcha after <N> unsuccessfull attempts

Created 5 years ago by zitterHow-tos7 comments – viewed 23,521 times – ( +15 / -6 ) – version 1.1
In this mini howto I would like to show how to add a required captcha field in the login form, after a defined number of unsuccessfull attempts. To do this, I will use the blog demo that you have in default Yii download package (path/to/yii/demos/blog).

Add Beautiful Radio/Checkbox Buttons To Grid

Created 4 years ago by waterloomattHow-tos1 comment – viewed 27,227 times – ( +10 / -3 ) – version 1.1
This is a tutorial on how to create slick looking status buttons to update a model's status via a grid. Note** This tutorial uses Yii Bootstrap for styling.

Date Picker by examples

Created 4 years ago by InterboyHow-tos6 comments – viewed 104,824 times – ( +10 / -3 ) – version 1.1
CJuiDatePicker displays a datepicker. CJuiDatePicker encapsulates the JUI datepicker plugin.

multiple CActiveDataProviders in one CGridView

Created 4 years ago by Kostas Apazidis (KonApaz)How-tos7 comments – viewed 24,004 times – ( +8 / -2 ) – version 1.1
There is a few cases that you want more of one CActiveDataProvider displayed in one CGrideView How to do that?

Popup AJAX DialogBox without any extension

Created 4 years ago by Kostas Apazidis (KonApaz)How-tos4 comments – viewed 21,851 times – ( +8 / -2 ) – version 1.1
In this wiki I explain how to show a default popup dialogbox (like Gii does) using an existing module.

How to use Expression in default AccessControl to allow only the owner to do some action

Created 4 years ago by whatifHow-tos2 comments – viewed 42,838 times – ( +8 / -2 ) – version 1.1
Hi Everyone

i18n All-in-one format and timezone conversions for date, time, timestamp and datetime.

Created 4 years ago by Gerhard LiebenbergHow-tos3 comments – viewed 22,916 times – ( +8 / -2 ) – version 1.1
Countries sometimes change their laws pertaining to time zones and daylight saving times. This means that GMT+2 can be a different local time this August compared to last August! It could even be a different date!

Creating a Dependent Dropdown From Scratch in Yii2

Created 3 years ago by ThePr0f3550rHow-tos4 comments – viewed 80,297 times – ( +8 / -2 ) – version 2.0
I have read (Dependen Dropdown Yii1), but I can't implement it in Yii2 because Yii2 does not have built-in AJAX functionality hem.. I searched about it and came across this post

Yet another implementation of CPhpAuthManager.

Created 4 years ago by seenivasanHow-tos3 comments – viewed 13,224 times – ( +8 / -2 ) – version 1.1
In this wiki, I try to implement a simple authorization schema without putting much logic inside a file or into database table. We are constructing authorization hierarchy inside the controller. We are getting roles for the current user from database table and assigning only roles to user that are declared in the particular controller. We have brought down the work of loading of auth data at main application level to controller level. This way we have pulverised auth data for entire site into smaller units. Finally we are going to look at couple of examples.