so i have a 1st model and controller for Files and 2th / controller and
model for Comments,
my question is - Can I use findAll() for Comments in files Controller ?

---------
class FilesController extends AppController{
        var $name='Files';

        var $components = array ('Pagination');
        var $helpers = array('Pagination','html');

        function index(){
                $files = $this->File->FindAll($criteria=NULL, NULL, $order, 
$limit,
$page,0);
                $this->set('files',$files);
                $this->render('index');
         }
 function view($id){
        $this->File->id = $id;
        $this->set( 'files', $this->File->read(null,null,null,3) );
        $this->set( 'neighbours', $this->File->findNeighbours(null,
'File.id', $id));
  // !!!!!!!!!
  // !!!!!!!!!
  // !!!!!!!  EXAMPLE i neeed this
  // !!!!!!!!!
$coments = $Comment->FindAll($criteria=NULL, NULL, $order, $limit,
$page,0);
                
$this->set('comments',$comments);

         }


------------------


--~--~---------~--~----~------------~-------~--~----~
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