Wiki

Articles in category "how-tos", sorted by date (updated)X
Displaying 151-160 of 182 result(s).

Sub-domains with different databases in Yii!

Updated about a year ago by jwerdHow-tos3 comments – viewed 7,937 times – ( +1 )
Sub-domains with different databases in Yii!

Single table inheritance

Updated about a year ago by samdarkHow-tos6 comments – viewed 13,644 times – ( +31 )
Relational databases do not support inheritance so if we need to represent it, we have to somehow store meta info while keeping performance by minimizing JOINs. One way to solve this problem is using single table inheritance. All fields for the whole class tree are stored in a single table. Class name is stored in the type field of the same table.

Local time zones and locales

Updated about a year ago by Russell EnglandHow-tos9 comments – viewed 30,213 times – ( +12 / -2 )
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.

How to install pdo_oci

Updated 2 years ago by Horacio SeguraHow-tos1 comment – viewed 12,360 times – ( +1 )
From: http://lacot.org/ and me.
tags: pdo oci php

Using Pear Mail Mail_Mime and Mail_Queue

Updated 2 years ago by LorenHow-tos2 comments – viewed 5,682 times – ( +7 )
Create a component (/protected/components/PearMail.php) Edit this as needed based on where you put the files from PEAR.

Converting an Artisteer Theme to Yii

Updated 2 years ago by bgleeHow-tos3 comments – viewed 14,949 times – ( +9 )
There are two approaches to converting an Artisteer theme. The first is to simply copy an existing Artisteer – based Yii theme, overlay the CSS and images, then make any necessary tweaks to the layout files. This is undoubtedly the fastest route, but won't teach you as much as doing it from scratch. That's ok. Sometimes getting the job done is the top priority. The second approach is more general and will apply to some extent to other HTML templates that you may want to convert. I'll be covering the first approach in detail, while the second will be more of a general discussion.

Keeping a running total in a CGridView

Updated 2 years ago by tydeas_drHow-tos3 comments – viewed 15,248 times – ( +21 )
This tip created in conjunction with IRC #yii channel users emilsedgh and tydeas - thanks!
tags: CGridView

How to avoid multiple Ajax Request

Updated 2 years ago by nickcvHow-tos11 comments – viewed 19,285 times – ( +13 )
CHtml::ajaxLink(), CHtml::ajaxSubmitButton() and similar methods are great, but if they are located inside a portion of the page that is already loaded via ajax something bad will happen, something you may even not notice if you are not using tools like firebugs: the sent ajax requests will multiply themselves.

Prevent asset publishing for CListView

Updated 2 years ago by MikeHow-tos2 comments – viewed 5,368 times – ( +2 )
If you don't want to use any of the AJAX features of CListView and thus want to prevent that it publishes any of its asset files, you can extend it and create a sub class like this:
tags: CListView, Assets

Uploading multiple images with CMultiFileUpload

Updated 2 years ago by Maurizio DombaHow-tos11 comments – viewed 41,960 times – ( +33 )
"The documentation for CMultiFileUpload isn't clear!"