Wiki

Sorted by commentsX
Displaying 111-120 of 782 result(s).

Relations: BELONGS_TO versus HAS_ONE

Created 5 years ago by Steve FriedlFAQs9 comments – viewed 118,595 times – ( +69 ) – version 1.1
It's very common to see new Yii users confusing the relations HAS_ONE and BELONGS_TO, and getting it wrong means you won't get proper values back. And though we'll talk about HAS_MANY as well, we're specifically omitting the MANY_MANY relation because it's a whole different animal.

How to generate Yii-like Documentation

Created 5 years ago by AsgarothHow-tos9 comments – viewed 32,532 times – ( +46 ) – version 1.1
Something a good application cant miss is documentation, and what would be better than some nice formatted HTML documentation that can be auto-generated from your code, we know several tools that already do this like phpDocumentor, but today we are introducing Yii Docs Generator which is a modification of the code that Yii itself uses to generate its documentation, thank phpnode for this wonderful work.
tags: doc

Local time zones and locales

Created 5 years ago by Russell EnglandHow-tos9 comments – viewed 68,308 times – ( +14 / -2 ) – version 1.1
Following on from international dates, I also wanted times in the local timezone and format. This was a little more tricky but I think I've got a solution. This is only really appropriate if you have an international app.

Send mail using YiiMail extension

Created 3 years ago by RKATutorials9 comments – viewed 65,854 times – ( +8 ) – version 1.1
Let me show a simpe example to send mail using YiiMail extension in 5 steps. It also includes any template view if required along with the content.
tags: YiiMail

How to use the official Yii installer for Composer (**DEPRECATED**)

Created 3 years ago by br0skHow-tos9 comments – viewed 38,529 times – ( +3 ) – version 1.1
This wiki shall be considered deprecated since the Yii installer for composer has been discontinued.

How to use single form to collect data for two or more models (CActiveForm and Ajax Validation edition)

Created 5 years ago by RusAlexHow-tos9 comments – viewed 53,896 times – ( +22 ) – version 1.1
With Yii you can use one CActiveForm for collecting data for two or more models with ajax validation and client validation.

Yiinitializr: The Library

Created 3 years ago by Antonio RamirezOthers9 comments – viewed 18,170 times – ( +15 ) – version 1.1
Introduction

Filter / Search with CListView

Created 5 years ago by JohnPollardHow-tos9 comments – viewed 41,350 times – ( +29 ) – version 1.1
This is what I did. Its the EASIEST solution that I know of. I just reused the advanced search done in CGridView.

Generate a multi-lever array sub-category for a menu

Created 3 years ago by Kostas Apazidis (KonApaz)How-tos8 comments – viewed 16,588 times – ( +10 ) – version 1.1
Everyone have seen a multilayer menu in several CMS

How to use bizRules in standard accessControl filter

Created 3 years ago by Maciej Li┼╝ewskiHow-tos8 comments – viewed 14,194 times – ( +3 ) – version 1.1
I assume you are familiar with accessControl standard filter. It allows you to separate privileges to run some action from action code itself. There is however one problem with most common usage - you cannot use bizRules, at least based on some parameters passed to 'checkAccess' just because it is hard to pass them in accessRules() result.