When you unpack Cake on your server you will find three main folders -
app
cake
vendors
The
cake
folder is where the core libraries for Cake
lay and you generally won't ever need to touch it.
The app folder is where your application specific
folders and files will go. The separation between the
cake folder and the app folder
make it possible for you to have many app folders sharing a single set
of Cake libraries. This also makes it easy to update CakePHP: you just
download the latest version of Cake and overwrite your current core
libraries. No need to worry about overwriting something you wrote for
your app.
You can use the vendors directory to keep third-party
libraries in. You will learn more about vendors later, but the basic
idea is that you can access classes you've placed in the vendors
directory using Cake's vendor() function.
Let's look at the entire file layout:
/app
/config - Contains config files for your database, ACL, etc.
/controllers - Controllers go here
/components - Components go here
/index.php - Allows you to deploy cake with /app as the DocumentRoot
/models - Models go here
/plugins - Plugins go here
/tmp - Used for caches and logs
/vendors - Contains third-party libaries for this application
/views - Views go here
/elements - Elements, little bits of views, go here
/errors - Your custom error pages go here
/helpers - Helpers go here
/layouts - Application layout files go here
/pages - Static views go here
/webroot - The DocumentRoot for the application
/css
/files
/img
/js
/cake - Cake's core libraries. Don't edit any files here.
index.php
/vendors - Used for server-wide third-party libraries.
VERSION.txt - Let's you know what version of Cake you're using.