(1)You can download 'decorate.php' from
http://cakeforge.org/projects/decorate/
copy it to cake/scripts
(2)Set your DB-table
(3)Start baking [decorating] by using Windows Command Prompt.
prompt> your_php_path\php.exe path\decorate.php
(4)Script will bake all the files for you.
(5)Goto http://localhost/cake/TABLENAME
(6)CRUD (Create, Read, Update, Delete) features
(7)CakePHP can handle "table associations"!
(8)Complex Sorting feature
(9)Filtering(Search) feature
(10)You can make your own "template" design files. or you can download from
http://cakephp.seesaa.net/article/20355864.html
If you just drop your template file to "layout", it will be...
(11)If you want "login" feature, CakePHP has already various types of authentification.
http://manual.cakephp.org/appendix/simple_user_auth
or if you just need only one username and password, you can download sd_auth from
http://cakeforge.org/snippet/detail.php?type=package&id=20
just "drop" the sd_auth file to app/controllers/components, and thtml desing file to app/view/layouts/. then,
Add following lines to app_controller.php(Copy from /cake to /app).
class AppController extends Controller {
var $components = array('SdAuth');
function beforeFilter()
{
// Auth Check.
if($this->SdAuth->isloggedin() == FALSE){
$this->layout = "login";
} else {
$this->layout = "default";
};
}
}




RoRより良いかも、軽快だし。
decorate.phpですが、AssociationsでbelongsToを選択したら、Viewのindex.thtmlの<?php foreach ($itemss as $item): ?>でインバリッドアーギュメントとなりました。
それを修正した後、表示すると1ページ目が11件表示されます。
リミットは10件なのに、2ページ目以降は10件表示されます。
とりあえず、気づいたことを。
1)二つのテーブルのDBスキーマはどうなっていますか?教えていただける範囲で……。
2)親は“has many”か"has one",子供は、“belongTo”を設定されているでしょうか……。また、子供のほうには、"親テーブル(単数形名)_id"がありますか?
単独テーブルなのでassociationsでn指定してエラーなしです。
ただ、ページ毎の表示件数はやはり先頭ページ11件、2ページ以降は10件のままでした。
件数の件は、見間違いでした。
idが1つ削除でなくなっていたので、1ページの最後がid=11と表示されていたので勘違いしました。
すみませんでした。