Wiki

Articles in category "how-tos", sorted by ratingX
Displaying 121-130 of 350 result(s).

CGridView. Add custom class to table rows preserving original „odd“ and „even“

Created 3 years ago by Maug LeeHow-tos2 comments – viewed 33,747 times – ( +8 ) – version 1.1
Lets say we have such a CGridView widget showing a list of users for administrator. Users have status „active“ or „disabled“. Grid widget puts class „odd“ or „even“ to rows and we want to preserve this. So we want to add a class „disabled“ to rows with disabled users.

How to setup RBAC with a php file

Created 6 years ago by bettorHow-tos17 comments – viewed 61,860 times – ( +26 / -5 ) – version 1.1
In this cookbook I will attempt to explain how to use the lightweight version of Role-Based Access Control using a php file. This version does not use database but a php file and is controlled by CPhpAuthManager class.

Updating fields on a form with Ajax and Json

Created 5 years ago by Russell EnglandHow-tos4 comments – viewed 53,804 times – ( +12 / -1 ) – version 1.1
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.

Model password confirmation field.

Created 4 years ago by twisted1919How-tos10 comments – viewed 66,583 times – ( +11 / -1 ) – version 1.1
I had some troubles with the password confirmation field for when adding updating user records, so i thought that i should share the way i got it working.

Use phing to make Yii application "installable"

Created 4 years ago by sensorarioHow-tos3 comments – viewed 8,848 times – ( +7 ) – version 1.1
To use this "how-to", you need to install phing in your machine.
tags: phing

Radio Button List with enum values for column of type ENUM >+> incorporate into giix

Created 4 years ago by pckabeerHow-tos1 comment – viewed 17,099 times – ( +7 ) – version 1.1
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 Radio Button List, which has the enum values as options. This is a rewrite of c@cba in the wiki article of enumDropdownListThe main code was contributed by zaccaria in the forum (see this post).

How to render a view in Fancybox using ajax

Created 3 years ago by rix.rix.How-tos1 comment – viewed 21,869 times – ( +7 ) – version 1.1
Sometimes you want to render a view in Fancybox.
tags: fancybox, ajax, views

Setting up PHPUnit and Selenium with IntelliJ IDEA/PhpStorm

Created 3 years ago by rAWTAZHow-tos0 comments – viewed 34,021 times – ( +7 ) – version 1.1
This article intends to summarize the steps taken to set up PHPUnit and Selenium for a Yii project, with IntelliJ IDEA Ultimate (the IDE). It was done on Mac OS X 10.6.

Elementary introduction to using jQuery ajax and the yii framework

Created 3 years ago by dhimesHow-tos4 comments – viewed 35,862 times – ( +7 ) – version 1.1
In doing internet searches trying to learn how to incorporated ajax into web pages generated by the yii framework I noticed that there seems to be a lot of confusion. I worry that too-clever hacks will be broken in upgrades of the framework.
tags: AJAX

How to send emails using SMTP

Created 2 years ago by robregonmHow-tos2 comments – viewed 38,151 times – ( +7 ) – version 2.0
Follow @robregonm
tags: yii2, email, mail, mailer, smtp