yii: CGridView and show detail in CJuiDialog

by prettyscripts on 2012-02-03 12:19:00 • Leave a comment »

misc

instead of going to a different page to view detail from a grid row, i'd like to show detail from pop-in / dialog box within the same page. i found an article from yii's documentation that does exactly that. the article provide solutions to open one or… more »

Tags: detail, dialog, grid, jquery, php, yii

yii: default value for date picker field and CJuiDatePicker

by prettyscripts on 2012-01-24 14:28:00 • Leave a comment »

phpyii

setting a default date value to a date picker field is not so straightforward. as in, simply set a property for the CJuiDatePicker widget. there are 2 ways to do it. these are based on some forum posts i found a while ago. method 1 - give the attribut… more »

Tags: date, default, php, yii

yii: autocomplete field with CJuiAutoComplete

by prettyscripts on 2012-01-20 14:17:00 • Leave a comment »

phpyii

i have previously written a post on the same topic with CAutoComplete. since CAutoComplete is depreciated (since V113) and replaced with CJuiAutoComplete, i should keep my notes up-to-dated. i find that this is easier to implement. i found a solution b… more »

Tags: ajax, autocomplete, jquery, php, yii

yii: save empty field as null

by prettyscripts on 2012-01-18 10:52:00 • Leave a comment »

phpyii

this is an updated post in reference to a previous post about saving a field to null when no value is entered. thanks to those who left comment, this is the correct (and easier!) way to do it. add a new rule to the model: protected funcion rules() {… more »

Tags: code, null, php, save, yii

yii: default view results to last page

by prettyscripts on 2011-10-25 12:36:00 • Leave a comment »

phpyii

i have pages of result and want to default the view to last page and found the solution here. in controller action function, more »

Tags: grid, last, list, page, yii