Moodle  2.2.1
http://www.collinsharper.com
quizaccess_securewindow Class Reference
Inheritance diagram for quizaccess_securewindow:
Collaboration diagram for quizaccess_securewindow:

Public Member Functions

 attempt_must_be_in_popup ()
 get_popup_options ()
 setup_attempt_page ($page)

Static Public Member Functions

static make (quiz $quizobj, $timenow, $canignoretimelimits)
static get_browser_security_choices ()

Static Protected Attributes

static $popupoptions

Detailed Description

A rule for ensuring that the quiz is opened in a popup, with some JavaScript to prevent copying and pasting, etc.

Definition at line 39 of file rule.php.


Member Function Documentation

Returns:
boolean whether this rule requires that the attemp (and review) pages must be displayed in a pop-up window.

Reimplemented from quiz_access_rule_base.

Definition at line 64 of file rule.php.

static get_browser_security_choices ( ) [static]
Returns:
array key => lang string any choices to add to the quiz Browser security settings menu.

Reimplemented from quiz_access_rule_base.

Definition at line 91 of file rule.php.

Returns:
array any options that are required for showing the attempt page in a popup window.

Reimplemented from quiz_access_rule_base.

Definition at line 68 of file rule.php.

static make ( quiz quizobj,
timenow,
canignoretimelimits 
) [static]

Return an appropriately configured instance of this rule, if it is applicable to the given quiz, otherwise return null.

Parameters:
quiz$quizobjinformation about the quiz in question.
int$timenowthe time that should be considered as 'now'.
bool$canignoretimelimitswhether the current user is exempt from time limits by the mod/quiz:ignoretimelimits capability.
Returns:
quiz_access_rule_base|null the rule, if applicable, else null.

Reimplemented from quiz_access_rule_base.

Definition at line 55 of file rule.php.

Here is the call graph for this function:

setup_attempt_page ( page)

Sets up the attempt (review or summary) page with any special extra properties required by this rule. securewindow rule is an example of where this is used.

Parameters:
moodle_page$pagethe page object to initialise.

Reimplemented from quiz_access_rule_base.

Definition at line 72 of file rule.php.

Here is the call graph for this function:


Field Documentation

$popupoptions [static, protected]
Initial value:
 array(
        'left' => 0,
        'top' => 0,
        'fullscreen' => true,
        'scrollbars' => true,
        'resizeable' => false,
        'directories' => false,
        'toolbar' => false,
        'titlebar' => false,
        'location' => false,
        'status' => false,
        'menubar' => false,
    )

Definition at line 41 of file rule.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations