After the Module is setup and configured correctly, it's time to add our own logic. This is what we had been waiting for!
The bulk of our logic goes into three scripts in our module's directory:
- view.php
- lib.php
- locallib.php
THE MODULE'S VIEW.PHP SCRIPT
This script handles the display of the activity once it is added to a course section. If we look at the code provided in the template, it already handles the following:
- Determining the instance of the module for the current course
- Entering the view as an the activity to the Moodle log
- Displaying the Moodle header and footer