reduced slideshow code