added anchorSlide function