Reset the media index to zero when the video is ended and play is called
Before the invoking the Flash tech's play(), check if the video has ended. If it has, reset the media index so that the video replays.