added post to \index to select page
cleaned up some function calls
cleaned up more. got the sub dir working