lots of javascript for the mountain index page, assorted sql business to try to make those queries work on the backend