Cohort Variables
Run a course twice and the content forks fast. Tuesday's section has Dana, Thursday's has Marcus, each group has its own Zoom room, and suddenly you're maintaining two copies of every page. Cohort variables end that: write the page once, and each member sees their own group's details.
The idea is simple. A cohort carries its own key/value pairs, instructor, section number, meeting link, start date, whatever you need. The [memb_cohort_info] shortcode looks up the current member's cohort for the course and prints the value. One page, every section.
The variables
On each cohort, set the keys your operation needs. Common ones:
| Key | What it holds | Example |
|---|---|---|
instructor_name |
Who leads this section | Dana Ortiz |
section_number |
Section identifier within the run | Section B |
meeting_link |
This group's live session room | https://zoom.us/j/... |
office_hours |
When the instructor is reachable | Thursdays, noon EST |
Two keys come built in: cohort_name and cohort_start_date. Everything else is yours to define.
The pages
On any page, post, or widget in the course, drop in the shortcode where that group's information belongs:
Your instructor: [memb_cohort_info key="instructor_name"]
Live sessions: [memb_cohort_info key="meeting_link"]
The welcome page writes itself once and stays correct for every section:
Welcome to [memb_cohort_info key="cohort_name"].
Your cohort began [memb_cohort_info key="cohort_start_date"],
and your instructor is [memb_cohort_info key="instructor_name"].
On a course page the shortcode resolves the course automatically. Elsewhere, name it:
[memb_cohort_info key="meeting_link" course_id="123"]
Defaults for members outside any cohort
Someone always slips through: the tester account, the annual all-access member, the guy who bought during the beta. Give every variable a default so those members see something sensible instead of a blank:
[memb_cohort_info key="instructor_name" default="The Torii team"]
What this buys you
The mechanical win is maintenance: N sections means N cohorts, not N page trees. Edit the syllabus once and every section sees it.
The subtler win is belonging. A page that names your instructor, your meeting room, and your start date tells the member they're in a specific group with specific people, and that's the whole psychological product of a cohort, delivered by a shortcode.