Notice: Undefined property: AppController::$Categoria in D:\DW\xampp
\htdocs\barato\app\app_controller.php on line 15
Fatal error: Call to a member function findAll() on a non-object in D:
\DW\xampp\htdocs\barato\app\app_controller.php on line 15
This error appears when acess some page, in others functions
and now?
On 22 maio, 20:45, SeanCallan <[EMAIL PROTECTED]> wrote:
> One way of implementing this would be as followed:
>
> app/app_controller.php
>
> <?php
>
> class AppController extends Controller
> {
>
> var $uses = array('Categoria');
>
> function beforeFilter(){
> $this->menu();
>
> }
>
> function menu(){
> // SELECIONA TODAS AS CATEGORIAS RAIZ
> $conditions = array("subCategoria" => "0");
> //$this -> set("dadosMenu", $this -> Categoria -> read());
>
> $this -> set("dadosMenu", $this -> Categoria -
>
> >findAllBy("Categoria.subCategoria = '0'")); // findBysubCategoria = 0
> }
> }
>
> ?>
>
> If I'm not mistaken that should work for you :)
--~--~---------~--~----~------------~-------~--~----~
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?hl=en
-~----------~----~----~----~------~----~------~--~---