You are here

function hook_course_enrol in Course 6

Notify modules about a course enrollment.

Parameters

object $node: The course node.

object $user: The enrolling user.

string $from: The type of enrollment, if applicable. {course_enrolment}.enrollmenttype.

string $code: The access code used to enroll. {course_enrolment}.code.

integer $status: The enrolment status. {course_enrolment}.status.

See also

course_enrol()

2 functions implement hook_course_enrol()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

course_signup_course_enrol in modules/course_signup/course_signup.module
Implements hook_course_enrol().
course_uc_course_enrol in modules/course_uc/course_uc.module
Implements hook_course_enrol().
1 invocation of hook_course_enrol()
course_enrol in ./course.module
Enrols a user in a course.

File

./course.api.php, line 241
Hooks provided by Course module.

Code

function hook_course_enrol($node, $user, $from, $code, $status) {

  // @todo add example.
}