Skip to content Skip to navigation

ExploreCourses and the Stanford Courses Drupal Module

In December, 2011, we released the Stanford Courses module for Drupal 6. This is a Features-based module that polls the XML feed at ExploreCourses and creates Course and Course Section nodes on a Drupal website.

Taking PWR 1AT: Writing & Rhetoric 1: A Mountain for Itself: The Rhetoric of Wilderness as our example, the Drupal Course node contains information such as:

  • Course title: Writing & Rhetoric 1: A Mountain for Itself: The Rhetoric of Wilderness
  • Number of credits: 4
  • General Education Requirements: Writing1
  • etc.

The Course Section nodes are the individual offerings of that course, including such information as:

  • Instructor: Todhunter, A
  • Dates and times: Tues/Thurs 1:15 - 3:05PM
  • Terms offered: Autumn, Winter
  • etc.

Initially, the concept was to import all Course and Course Section nodes and create CCK Nodereference relationships between them (Drupal 6).

After using this module for several months and deploying it in production on several sites, we have realized several limitations with this approach:

  • When a course section is deleted on ExploreCourses, it is not deleted on the Drupal site
  • When a tag is deleted from a course on ExploreCourses, if the course was previously imported to your Drupal site with that tag, it will retain that tag

In short, data that is removed on ExploreCourses will be retained on your Drupal site.

Because course sections are volatile and subject to change, we have added a field on all course nodes that links to the course listing on ExploreCourses. Users are encouraged only to import course information and refer to the listings on ExploreCourses for up-to-date section information.

The Drupal 7 version of the Stanford Courses module currently does include a Course Section content type and associated importer. However, due to the limitations described above, the Course Section functionality will be removed in future versions of the Drupal 7 version.

Special thanks to Stephen Shireffs and his team in the Office of the University Registrar for working with us behind the scenes to get a working course importer.