From 1d729693961dfa4cf4da45a05d703b392dbcb47f Mon Sep 17 00:00:00 2001
From: Fabio Bas
+In the blog demo project, we need to create two Active Record classes, UserRecord and PostRecord, to represent data records in the users and posts tables, respectively. Active Record classes must extend from the base class ActiveRecord, and must define property names that matches with the field names of the corresponding table. +
+ ++To better organize our directories, we create a new directory protected/database to hold the class files. We also modify our application configuration by inserting the following lines. It is equivalent to adding the directory protected/database to PHP include_path, which allows us to use the classes without explicitly including them. +
+ ++At the prompt, enter the following two commands to create UserRecord and PostRecord classes: +
+ ++Here we used the namespace format again to specify the classes to be created. The path Application.database.UserRecord indicates that we want the UserRecord class file to be protected/database/UserRecord.php. +
+ +>>>>>>> ef81c44... Quickstart Doc overhaul, pt. 2: active controls + minor fixes -- cgit v1.2.3