Wiki

Sorted by ratingX
Displaying 371-380 of 719 result(s).

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

Created about a year ago by whatifHow-tos1 comment – viewed 18,745 times – ( +7 / -1 ) – version 1.1
Hi Everyone

get summary of related model via STAT relation

Created about a year ago by rootbearHow-tos2 comments – viewed 9,118 times – ( +7 / -1 ) – version 1.1
typical scenario: invoice, invoice items.

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

Created about a year ago by Gerhard LiebenbergHow-tos3 comments – viewed 12,564 times – ( +7 / -1 ) – version 1.1
Countries sometimes change their laws pertaining to timezones and daylight saving times. This means that GMT+2 can be a different time this August compared to last August! However, by using php's DateTime class (instead of timestamps), we can do both "format" and "timezone" conversions on a single DateTime object (only 2 lines of code) for date, time, timestamp and datetime types - while php takes care of nightmares such as current and historical timezones and daylight saving times.

How to "masquerade" a non-required form element as 'required' one (in the view only)

Created 2 years ago by BoazHow-tos2 comments – viewed 9,080 times – ( +7 / -1 ) – version 1.1
In a nutshell, the task at hand is to mark (or render) a model attribute in the typical "_form.php" view file with the 'required' red asterisk while this attribute is not marked as required in the model's rule() method. If you're interested only in the solution, jump ahead to the 'solution' section below.

Yii registry, how to use it, does it exist at all?

Created 3 years ago by dckurushinHow-tos2 comments – viewed 18,671 times – ( +7 / -1 ) – version 1.1
From time to time people ask about registry...

Ajax form submiting in Yii

Created 2 years ago by sirin kTutorials10 comments – viewed 90,049 times – ( +13 / -4 ) – version 1.1
hi guys, Here I'm going to give you a working example of ajax form submiting in Yii.

How to include Javascript, CSS

Created about a year ago by InterboyHow-tos3 comments – viewed 306,562 times – ( +9 / -2 ) – version 1.1
There are many methods that we can include javascript, css into your Yii App. Today I will demonstrate three simple and helpul methods.

Date Picker by examples

Created about a year ago by InterboyHow-tos6 comments – viewed 49,408 times – ( +9 / -2 )
CJuiDatePicker displays a datepicker. CJuiDatePicker encapsulates the JUI datepicker plugin.

Saving files to a blob field in the database

Created 4 years ago by zaccariaTips8 comments – viewed 43,075 times – ( +9 / -2 ) – version 1.1
As a follow-up from the How to upload a file using a model wiki entry that explains how to save a file to the filesystem, this article will do the same using a blob field in the database.
tags: File upload

Simple Mail Queue

Created about a year ago by waterloomattTutorials1 comment – viewed 8,975 times – ( +9 / -2 )
This tutorial shows how to create a simple mail queue. It is usually run from a cron job but can be run from the command line too.