1. Go to this page and download the library: Download blainesch/li3_fake_model library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
blainesch / li3_fake_model example snippets
class Posts extends Model {
public $hasMany = array(
'Comments' => array(
'to' => 'Comments', // The model
'key' => array('_id' => 'comment_id'), // or, you can use an array of foreign keys, e.g. array('comment_ids' => '_id')
'fieldName' => 'comments', // The key it's on
// `order`, `limit`, `conditions` can also be used
),
);
}