The AppController.php is part of the default download of CakePHP in all
versions. I just downloaded a fresh copy of CakePHP 2.3.0-RC1 and within
the app/Controllers directory there is in fact an AppController.php file.
 You shouldn't need to re-create the file unless you deleted it.


On Wed, Dec 19, 2012 at 8:23 AM, OxfordRob <pestle...@gmail.com> wrote:

> As a follow up....I am suspicious in this area....
>
> The tutorial says "To add this component to your application *open* your
> app/Controller/AppController.php file and *add* the following lines:"
>
> But this is the first mention of an 'AppController.php' file.
>
> So I just created an 'AppController.php' file and put in the code, but
> that does not feel right to me.
>
> I already have a 'UsersController.php' file that contains the class
> definition:
>
> class UsersController extends AppController
>
> So that makes me thing that 'AppController' is a pre-defined class in
> cake. Am I meant to be overloading this class?
>
> Something seems wrong.
>
> Any ideas please?
>
>
>
> On Wednesday, 19 December 2012 12:24:34 UTC, OxfordRob wrote:
>>
>> Folks,
>>
>> I successfully worked through the blog tutorial and everything worked
>> fine.
>>
>> I then moved onto the Authentication example / tutorial here...but can't
>> make it work..
>>
>> http://book.cakephp.org/2.0/**en/tutorials-and-examples/**
>> blog-auth-example/auth.html<http://book.cakephp.org/2.0/en/tutorials-and-examples/blog-auth-example/auth.html>
>>
>> I get a gibberish error message when I access the page... (Copied below)
>> which does not give me any real clues about what I have done wrong.
>>
>> Does anybody know where to download the full source code for this
>> example? Or, if you have made this work, would you post it please?
>>
>> Any clues about how to read the error message below, and where I might
>> start looking would be very gratefully received!
>>
>> I have attached zip of my /app directory.
>>
>> Thanks for any help!
>>
>>
>> *Error message:* on accessing URL: http://localhost/cakephp-2.3.**
>> 0-RC1/users/add <http://localhost/cakephp-2.3.0-RC1/users/add>
>>
>> Fatal error: Class declarations may not be nested in
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Error/**ExceptionRenderer.php on
>> line 55 Call Stack: 0.0014 354512 1. {main}() /var/www/cakephp-2.3.0-RC1/
>> **app/webroot/index.php:0 0.1175 2937464 2. Dispatcher->dispatch()
>> /var/www/cakephp-2.3.0-RC1/**app/webroot/index.php:97 0.1438 3490652 3.
>> Dispatcher->_getController() /var/www/cakephp-2.3.0-RC1/**
>> lib/Cake/Routing/Dispatcher.**php:152 0.1438 3490652 4.
>> Dispatcher->_loadController() /var/www/cakephp-2.3.0-RC1/**
>> lib/Cake/Routing/Dispatcher.**php:228 0.1440 3491896 5. class_exists()
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Routing/Dispatcher.**php:259
>> 0.1440 3492168 6. App::load() 
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Core/App.php:0
>> 0.1458 3537372 7. App::shutdown() 
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Core/App.php:0
>> 0.1468 3537344 8. App::_checkFatalError() 
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Core/App.php:899
>> 0.1470 3538456 9. call_user_func() 
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Core/App.php:926
>> 0.1470 3538500 10. ErrorHandler::handleError() /var/www/cakephp-2.3.0-RC1/
>> **lib/Cake/Core/App.php:0 0.1471 3538992 11. 
>> ErrorHandler::**handleFatalError()
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Error/ErrorHandler.**php:161
>> 0.1481 3548532 12. call_user_func() /var/www/cakephp-2.3.0-RC1/**
>> lib/Cake/Error/ErrorHandler.**php:211 0.1481 3548560 13.
>> ErrorHandler::handleException(**) /var/www/cakephp-2.3.0-RC1/**
>> lib/Cake/Error/ErrorHandler.**php:0 0.1488 3550236 14. App::load()
>> /var/www/cakephp-2.3.0-RC1/**lib/Cake/Core/App.php:0
>>
>>  --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.


Reply via email to