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

Public Member Functions

 validation ($data, $files)

Protected Member Functions

 definition ()
 validate_uploaded_file ($data, $errors)

Detailed Description

Form to import questions into the question bank.

Definition at line 38 of file import_form.php.


Member Function Documentation

definition ( ) [protected]

Abstract method - always override!

Reimplemented from moodleform.

Definition at line 40 of file import_form.php.

Here is the call graph for this function:

validate_uploaded_file ( data,
errors 
) [protected]

Checks that a file has been uploaded, and that it is of a plausible type.

Parameters:
array$datathe submitted data.
array$errorsthe errors so far.
Returns:
array the updated errors.

Definition at line 113 of file import_form.php.

Here is the call graph for this function:

Here is the caller graph for this function:

validation ( data,
files 
)

Dummy stub method - override if you needed to perform some extra validation. If there are errors return array of errors ("fieldname"=>"error message"), otherwise true if ok.

Server side rules do not work for uploaded files, implement serverside rules here if needed.

Parameters:
array$dataarray of ("fieldname"=>value) of submitted data
array$filesarray of uploaded files "element_name"=>tmp_file_path
Returns:
array of "element_name"=>"error_description" if there are errors, or an empty array if everything is OK (true allowed for backwards compatibility too).

Reimplemented from moodleform.

Definition at line 146 of file import_form.php.

Here is the call graph for this function:


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