Details
-
Type:
Improvement
-
Status:
Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: 1.9.2
-
Fix Version/s: None
-
Component/s: Themes
-
Labels:None
-
Environment:apache 2 , php 5 , mysql 5 , linux os , moodle 1.9.2
-
Database:MySQL
-
Affected Branches:MOODLE_19_STABLE
Description
a simple patch to let each course set its own visual preferences using a personal CSS.
1. duplicate any theme you like and call it my-style (for example)
2. add these lines to header.html inside the <head> tag , just after line 7.
<?php $id = optional_param('id', 0, PARAM_INT); ?>
<link rel="stylesheet" type="text/css" href="<?php echo '/moodle/file.php/'.$id.'/my-style.css' ?>" />
3. create a new CSS file in you personal course and call it "my-style.css" (in the course's main folder)
4. navigate to "course settings" and choose the theme "my-style" (if that was the name you gave it in instruction 1)
5. that's it ![]()
An alternative may be to add an import command so that a standard theme could still be applied and my-style.css be used to merely override or add some style definitions.