This is my script for creating the course index