You are here

function hook_course_outline_completion_links_alter in Course 7

Same name and namespace in other branches
  1. 8.3 course.api.php \hook_course_outline_completion_links_alter()
  2. 8.2 course.api.php \hook_course_outline_completion_links_alter()
  3. 7.2 course.api.php \hook_course_outline_completion_links_alter()
  4. 3.x course.api.php \hook_course_outline_completion_links_alter()

Allow modules to add links to the course completion landing page, such as post-course actions.

Parameters

array $links: By reference. Currently an array of three elements:

  • 0: $path param for l().
  • 1: $text param for l().
  • 2: A description, suitable for theme_form_element().

object $course_node: The course node object.

object $account: The user who just took the course.

See also

course_completion_page()

1 function implements hook_course_outline_completion_links_alter()

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

course_certificate_course_outline_completion_links_alter in modules/course_certificate/course_certificate.module
Implements hook_course_outline_completion_links_alter().
1 invocation of hook_course_outline_completion_links_alter()
course_completion_page in includes/course.outline.inc
Render a landing page for course completion.

File

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

Code

function hook_course_outline_completion_links_alter(&$links, $course_node, $account) {

  // Example: add a link.
  $links['gohome'] = array(
    t('Go home!'),
    '<front>',
    t('If you got this far, you
    deserve a link back home'),
  );
}