added js for gallery page