Note: You are currently viewing documentation for Moodle 1.9. Up-to-date documentation for the latest stable version is available here: Creating Moodle site data directory/Data directory.

Creating Moodle site data directory/Data directory

From MoodleDocs

The Moodle data directory (often called moodledata) contains course and site information that is accessible from the web by many users. Each site will differ.

Security warning: It is CRITICAL that this directory is NOT accessible directly via the web. If someone from the web can enter a url in their browser and reach any of the data directory sub directories, then your site will have major problem. There are some user of the web who are NOT friendly and enjoy finding weaknesses and then causing havoc.

Sub directories

  • Courses folder are labeled with their course id numbers
  • cashe
  • lang - holds other language directories, or edited language php files
  • sessions - holds session information for users
  • temp - has subfolders for backup, csvimport, unzip, typo3temp and other directories
  • upgradelogs - hold logfiles generated when Moodle upgraded
  • user - each user has a folder that is labeled with their user id
Example of moodledata folder in a Windows localhost server

See also

Creating Moodle site data directory - When the data directory is not created in the install process

Development:File API - the 2.0 Moodle file handling system uses the data director