Id like to be able to change some key display screens in Moodle. This involves changing and adding significant code to standard Moodle release files. The problem with that is I also want to be able to stay up to date with the new Moodle releases and changing these functions will make that difficult.
As an example, I would like to change the way the category and topic index pages display, using side boxes. This involves changing the course/lib.php, course/index.php and course/category.php files as a minimum.
The problem is that these changes are not likely desired by anyone else, and therefore really cant be part of the main release, and I dont want to fork.
So, can we implement a method that would allow local display routines to be added that would not impact the main Moodle release? As a suggestion, we could add checks for files with "local-" prefixes and include them if present. This could be added to the main release of Moodle without affecting its function, and would allow updates to be done with minor impact on local changes.
As an example, I would add the following lines to course/lib.php, probably after the define statements:
if (file_exists("$CFG->dirroot/course/local-lib.php")) {
include_once("$CFG->dirroot/course/local-lib.php");
}
The local- file would have all of the local changes Ive added, and would not impact the main release.
Thoughts? Is there already a way to do this that I've missed?
mike