fix modal scroller problem
added some minor template changes