You are here

function course_node_load in Course 7

Same name and namespace in other branches
  1. 7.2 course.module \course_node_load()

Implements hook_node_load().

File

./course.module, line 809
course.module Core functionality for Courses.

Code

function course_node_load($nodes, $types) {
  $result = db_query('SELECT * FROM {course_node} WHERE nid IN (:nids)', array(
    ':nids' => array_keys($nodes),
  ));
  while ($row = $result
    ->fetch(PDO::FETCH_ASSOC)) {
    $nodes[$row['nid']]->course = $row;
  }
}