Note: You are currently viewing documentation for Moodle 3.6. Up-to-date documentation for the latest stable version of Moodle is likely available here: Theme directory.

Theme directory: Difference between revisions

From MoodleDocs
No edit summary
 
No edit summary
Line 3: Line 3:
In the standard Moodle distribution, all themes are placed in the theme/ directory.
In the standard Moodle distribution, all themes are placed in the theme/ directory.


Moodle is flexible and starting with 1.7, moodle will fully support changing the location of themes for use with the theme selector.
Moodle is flexible and starting with 1.7, moodle will fully support changing the location of the theme directory.




Line 10: Line 10:
Starting from Moodle 1.7, the location of themes may be altered, using the variables ''$CFG->themewww'' and ''$CFG->themedir'' - themes from placed in the specified directory will be able to be selected using the theme selector.
Starting from Moodle 1.7, the location of themes may be altered, using the variables ''$CFG->themewww'' and ''$CFG->themedir'' - themes from placed in the specified directory will be able to be selected using the theme selector.


If you wish to place themes in a subdirectory called 'my_moodle_themes', your config.php might look like this:
For example, should you wish to place themes in a subdirectory called 'my_moodle_themes', your config.php might look like this:
<pre>
<pre>
$CFG->wwwroot  = 'http://my.moodle.site.edu';
$CFG->wwwroot  = 'http://my.moodle.site.edu';

Revision as of 13:36, 8 October 2006


In the standard Moodle distribution, all themes are placed in the theme/ directory.

Moodle is flexible and starting with 1.7, moodle will fully support changing the location of the theme directory.


Changing theme Location

Starting from Moodle 1.7, the location of themes may be altered, using the variables $CFG->themewww and $CFG->themedir - themes from placed in the specified directory will be able to be selected using the theme selector.

For example, should you wish to place themes in a subdirectory called 'my_moodle_themes', your config.php might look like this:

$CFG->wwwroot   = 'http://my.moodle.site.edu';
$CFG->dirroot   = '/var/www/my.moodle.site.edu/public_html';
$CFG->themewww  = $CFG->wwwroot . '/my_moodle_themes';
$CFG->themedir  = $CFG->dirroot . '/my_moodle_themes';