Sort Rows in Class Listings Tables

Objective


Control the order in which classes appear in a Class Listings Table.

Solution


Use the sort parameter to control the order of rows in a Class Listings Table. For example, you can sort classes by Category, Day, Time, Session, or Instructor.

How Sorting Works

To sort rows in a Class Listing Table, add a parameter the end of your basic table code or link using an ampersand (&).

A parameter includes:

  • A variable
  • A value 
  • An equals sign (=) between them

Example: sort=Days

The variable used for sorting columns is sort.

A sort parameter can include multiple values separated by commas.

Available Sort Values

  • Ages
  • Cat1
  • Cat2
  • Cat3
  • Class
  • Days
  • Description
  • Duration
  • EndDate
  • Gender
  • Instructors
  • Location
  • Openings
  • Room
  • Session
  • StartDate
  • StartTime
  • Tuition

Notes:

  • When you use a sort parameter, information is automatically sorted in ascending order (smallest to largest, A to Z).
  • To sort in descending order instead, add "desc" after the sort value. For example, to sort a table based on the number of class openings from highest to lowest, you would use the parameter sort=Openingsdesc.

Example

Customize the basic Class Listings table for Organization ID XXXXXX to sort first by Openings and then by Times.

Example JavaScript

<script type="text/javascript" src="https://app.jackrabbitclass.com/jr3.0/Openings/OpeningsJS?OrgID=XXXXXX&sort=Openings,Times"></script>

Example Direct URL

https://app.jackrabbitclass.com/jr3.0/Openings/OpeningsDirect?OrgID=XXXXXX&sort=Openings,Times

ℹ️Tip: To preview your changes while building your Class Listing Tables, open your basic table URL in a browser window. Add parameters and refresh the page to see the updated results.

Was this article helpful?
0 out of 0 found this helpful