scroll function in main controller. still need to figure out how to make clicking links call it.