mirror of
https://github.com/moodle/moodle.git
synced 2025-04-16 22:15:24 +02:00
NO CODE CHANGES. Just added PHPdoc comments at the top of lesson files.
This commit is contained in:
parent
a1069b070a
commit
5491947aa1
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/************** add cluster ************************************/
|
||||
|
||||
/**
|
||||
* Action for adding a cluster page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
// first get the preceeding page
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/************** add end of branch ************************************/
|
||||
|
||||
/**
|
||||
* Action for adding an end of branch page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
// first get the preceeding page
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/************** add end of cluster ************************************/
|
||||
|
||||
/**
|
||||
* Action for adding an end of cluster page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
// first get the preceeding page
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/******************* confirm delete ************************************/
|
||||
|
||||
/**
|
||||
* Action for confirming the deletion of a page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
$pageid = required_param('pageid', PARAM_INT);
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/****************** continue ************************************/
|
||||
|
||||
/**
|
||||
* Action for processing page answers by users
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
// left menu code
|
||||
|
@ -1,6 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/******************* delete ************************************/
|
||||
/**
|
||||
* Action for deleting a page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
$pageid = required_param('pageid', PARAM_INT);
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/****************** insert page ************************************/
|
||||
|
||||
/**
|
||||
* Action for processing the form from addpage action and inserts the page.
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
// check to see if the cancel button was pushed
|
||||
|
@ -1,6 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/****************** move ************************************/
|
||||
/**
|
||||
* Action that displays an interface for moving a page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
$pageid = required_param('pageid', PARAM_INT);
|
||||
$title = get_field("lesson_pages", "title", "id", $pageid);
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/****************** moveit ************************************/
|
||||
|
||||
/**
|
||||
* Action for actually moving the page (database changes)
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
$pageid = required_param('pageid', PARAM_INT); // page to move
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?php // $Id$
|
||||
|
||||
/****************** update page ************************************/
|
||||
|
||||
/**
|
||||
* Action for processing the form in editpage action and saves the page
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
confirm_sesskey();
|
||||
|
||||
$redirect = optional_param('redirect', '', PARAM_ALPHA);
|
||||
|
@ -1,8 +1,11 @@
|
||||
<?PHP //$Id$
|
||||
|
||||
//This php script contains all the stuff to backup/restore
|
||||
//lesson mods
|
||||
|
||||
<?php //$Id$
|
||||
/**
|
||||
* Lesson's backup routine
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
//This is the "graphical" structure of the lesson mod:
|
||||
//
|
||||
// lesson_default lesson ----------------------------|--------------------------|--------------------------|
|
||||
|
@ -1,10 +1,12 @@
|
||||
<?PHP // $Id$
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
/// format.php - Default format class for file imports/exports. //
|
||||
/// //
|
||||
/// Doesn't do everything on it's own -- it needs to be extended. //
|
||||
////////////////////////////////////////////////////////////////////
|
||||
<?php // $Id$
|
||||
/**
|
||||
* format.php - Default format class for file imports/exports. Doesn't do
|
||||
* everything on it's own -- it needs to be extended.
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
// Included by import.php
|
||||
|
||||
|
@ -1,5 +1,11 @@
|
||||
<?PHP // $Id$
|
||||
// Import quiz questions into the given category
|
||||
<?php // $Id$
|
||||
/**
|
||||
* Imports lesson pages
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
require_once("../../config.php");
|
||||
require_once("lib.php");
|
||||
|
@ -1,11 +1,17 @@
|
||||
<?php
|
||||
//This is a very rough importer for powerpoint slides
|
||||
//Export a powerpoint presentation with powerpoint as html pages
|
||||
//Do it with office 2002 (I think?) and no special settings
|
||||
//Then zip the directory with all of the html pages
|
||||
//and the zip file is what you want to upload
|
||||
|
||||
// supports book and lesson
|
||||
<?php // $Id$
|
||||
/**
|
||||
* This is a very rough importer for powerpoint slides
|
||||
* Export a powerpoint presentation with powerpoint as html pages
|
||||
* Do it with office 2002 (I think?) and no special settings
|
||||
* Then zip the directory with all of the html pages
|
||||
* and the zip file is what you want to upload
|
||||
*
|
||||
* The script supports book and lesson.
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
require_once("../../config.php");
|
||||
require_once("locallib.php");
|
||||
|
@ -1,6 +1,11 @@
|
||||
<?PHP // $Id$
|
||||
|
||||
/// This page lists all the instances of lesson in a particular course
|
||||
<?php // $Id$
|
||||
/**
|
||||
* This page lists all the instances of lesson in a particular course
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
require_once("../../config.php");
|
||||
require_once("locallib.php");
|
||||
|
@ -1,23 +1,25 @@
|
||||
<?PHP // $Id: lesson.php, v 1.0 25 Jan 2004
|
||||
|
||||
/*************************************************
|
||||
ACTIONS handled are:
|
||||
|
||||
addbranchtable
|
||||
addendofbranch
|
||||
addcluster
|
||||
addendofcluster
|
||||
addpage
|
||||
confirmdelete
|
||||
continue
|
||||
delete
|
||||
editpage
|
||||
insertpage
|
||||
move
|
||||
moveit
|
||||
updatepage
|
||||
|
||||
************************************************/
|
||||
<?php // $Id: lesson.php, v 1.0 25 Jan 2004
|
||||
/**
|
||||
* Handles lesson actions
|
||||
*
|
||||
* ACTIONS handled are:
|
||||
* addbranchtable
|
||||
* addendofbranch
|
||||
* addcluster
|
||||
* addendofcluster
|
||||
* addpage
|
||||
* confirmdelete
|
||||
* continue
|
||||
* delete
|
||||
* editpage
|
||||
* insertpage
|
||||
* move
|
||||
* moveit
|
||||
* updatepage
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
require("../../config.php");
|
||||
require("locallib.php");
|
||||
|
@ -1,15 +1,14 @@
|
||||
<?PHP // $Id$
|
||||
// modified by mnielsen
|
||||
/// Update: The lib.php now contains only the functions that are
|
||||
/// used outside of the lesson module. All functions (I hope) that are only local
|
||||
/// are now in locallib.php.
|
||||
|
||||
/// Library of functions and constants for module lesson
|
||||
<?php // $Id$
|
||||
/**
|
||||
* Standard library of functions and constants for lesson
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
define("LESSON_MAX_EVENT_LENGTH", "432000"); // 5 days maximum
|
||||
|
||||
/// (replace lesson with the name of your module and delete this line)
|
||||
|
||||
/*******************************************************************/
|
||||
function lesson_add_instance($lesson) {
|
||||
/// Given an object containing all the necessary data,
|
||||
|
@ -1,7 +1,12 @@
|
||||
<?php // $Id$
|
||||
/// mnielsen
|
||||
/// locallib.php is the new lib file for lesson module.
|
||||
/// including locallib.php is the same as including the old lib.php
|
||||
/**
|
||||
* Local library file for Lesson. These are non-standard functions that are used
|
||||
* only by Lesson.
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
/**
|
||||
* Next page -> any page not seen before
|
||||
|
@ -1,8 +1,16 @@
|
||||
<?php
|
||||
// This file plays the mediafile set in lesson settings
|
||||
// Almost all of this code is from /mod/resource/type/file/resource.class.php so major props for resource
|
||||
// If there is a way to use the resource class instead of this code, please change to do so
|
||||
// because I could not figure it out
|
||||
<?php // $Id$
|
||||
/**
|
||||
* This file plays the mediafile set in lesson settings.
|
||||
*
|
||||
* Almost all of this code is from /mod/resource/type/file/resource.class.php so major props for resource
|
||||
*
|
||||
* If there is a way to use the resource class instead of this code, please change to do so
|
||||
*
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
require_once('../../config.php');
|
||||
require_once($CFG->libdir.'/filelib.php');
|
||||
|
@ -1,6 +1,13 @@
|
||||
<!-- define a new instance of lesson -->
|
||||
<!-- It is used from /course/mod.php. The whole instance is available as $form. -->
|
||||
<?php
|
||||
<?php // $Id$
|
||||
/**
|
||||
* Define a new instance of lesson or edit an instance.
|
||||
* It is used from /course/mod.php. The whole instance is available as $form.
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
require("$CFG->dirroot/mod/lesson/locallib.php"); // for parameter array
|
||||
if ($form->mode == "add") {
|
||||
if ($defaults = get_record("lesson_default", "course", $form->course)) {
|
||||
|
@ -1,5 +1,12 @@
|
||||
<?php
|
||||
// jjg7:8/9/2004
|
||||
<?php // $Id$
|
||||
/**
|
||||
* jjg7:8/9/2004
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
function removedoublecr($filename) {
|
||||
// This function will adjust a file in roughly Aiken style by replacing extra newlines with <BR> tags
|
||||
// so that instructors can have newlines wherever they like as long as the overall format is in Aiken
|
||||
|
@ -1,7 +1,11 @@
|
||||
<?PHP //$Id$
|
||||
|
||||
//This php script contains all the stuff to backup/restore
|
||||
//lesson mods
|
||||
<?php //$Id$
|
||||
/**
|
||||
* This php script contains all the stuff to restore lesson mods
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
//This is the "graphical" structure of the lesson mod:
|
||||
//
|
||||
|
@ -1,9 +1,12 @@
|
||||
<?PHP // $Id$
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
/// Code fragment to define the version of lesson
|
||||
/// This fragment is called by moodle_needs_upgrading() and /admin/index.php
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
<?php // $Id$
|
||||
/**
|
||||
* Code fragment to define the version of lesson
|
||||
* This fragment is called by moodle_needs_upgrading() and /admin/index.php
|
||||
*
|
||||
* @version $Id$
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License
|
||||
* @package lesson
|
||||
**/
|
||||
|
||||
$module->version = 2006091801; // The current module version (Date: YYYYMMDDXX)
|
||||
$module->requires = 2006080900; // Requires this Moodle version
|
||||
|
Loading…
x
Reference in New Issue
Block a user