add preloader.gif image and logic.