i have a users table and a articles table.

if i have a controller with scaffolding turned on, the edit works fine,
and the select menu appears correctly with the name of each user.

however if i bake the controller and view, i get an error

Notice: Undefined variable: created_byArray in
/home/pwg/Subversion/sandboxes/mikevh-420/admin/cake/app/views/articles/edit.thtml
on line 32

users model -
<?php class User extends AppModel
{
        var $name = 'User';

        var $hasMany = array(
                        'Article' =>
                         array('className' => 'Article',
                                        'foreignKey' => 'created_by' ),
        );
}?>

articles model -
<?php class Article extends AppModel
{
        var $name = 'Article';
        var $useTable = 'kb_articles';

        var $belongsTo = array(
                        'User' =>
                         array('className' => 'User',
                                        'foreignKey' => 'created_by' ),
);  } ?>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~----------~----~----~----~------~----~------~--~---

Reply via email to