Tag Archive
The following is a list of all entries tagged with yii:
Using Our Models To Do Basic Queries On The DB
Filed in tutorials, 23/06/2011, 22:37The application has an auto-generated model, Gii kindly provides the model once the database is created. 01<?php02class Product extends CActiveRecord03{04 /**05 * The followings are the available columns in table ‘Product’:06 * @var integer $id07 * @var integer $brandId08 * @var string $name09 * @var string $price10 */11 12 /**13 * Returns the static model of [...]
YiiFramework adding functions to your models
Filed in tutorials, , 22:16MVC has some principals to it, like the fat model principal that I’ll show in this tutorial and which is used in a lot of frameworks. I’m going to show how to add and use functions that can be added to a model. There are a few ways to add to a models that increase [...]
mySQL view and YiiFramework
Filed in tutorials, , 19:03The sql standard gives the possibility to create a view, a view is or can be a mask of one column for a special user that only has access to some of the data and thus not all the data stored in the column? The view can also be used to regroup data from multiple [...]
SQL & Yii
Filed in General, 21/06/2011, 19:35At school, I have a course ORACLE SQL which learned me some new tricks and options, I’ve also been testing them in MySQL and so the idea grew to see how Yii framework would interact with those tricks. I must say I didn’t expect them to work but they do so probably within the next [...]
Yiiframework Captcha problem
Filed in post, 23/02/2011, 15:48While lanching a new website I had problems with the AJAX request allowing the captcha to refresh itself. The link ‘Get a new code’ didn’t work properly and I didn’t really find an alternative at first. The only alternative I found it to add in the $this->widget(); add an array after ‘CCaptcha’: Share on Facebook
Yii framework: RBAC
Filed in General, 16/02/2011, 19:44Rbac in the Yiiframework isn’t hard at all but how do you keep your db clean and readable code readable and logic! After you have successfully configured the RBAC in /protected/config/main.php you need to insert the sql into your database and introduce your rules and accesses into to table, mine looks like this: And my [...]
Yii framework saving models to database
Filed in post, 17/11/2010, 22:05Recently i’ve been writing on my authentication and account modules, especially the SignUpModule has been some sort of a real pain. I only now realize what it was. Yii only saved my first model after which it apparently said goodbye to saving to the db. Luckily or not, I found a link on the Yii [...]