+ 7

CSS preloader

I need some help with my code actually I want that preloader div to get faded out after 5 seconds but the JavaScript is not working here's the code https://code.sololearn.com/WnoXVEa0y5tX/?ref=app

5th Jun 2018, 12:07 PM
Ayush
Ayush - avatar
5 Respostas
+ 4
$(document).ready(function () { $('.preloader').delay(5000).fadeOut(1000); }); add this jQuery
5th Jun 2018, 12:11 PM
Raj Chhatrala
Raj Chhatrala - avatar
+ 8
Raj Chhatrala this will work properly but I was thinking that will this work with all links and page opens just like real website have a common preloader that works with all window load events???
5th Jun 2018, 12:15 PM
Ayush
Ayush - avatar
+ 8
thank you Raj Chhatrala
5th Jun 2018, 12:18 PM
Ayush
Ayush - avatar
+ 4
the code will remain same Ayush Gupta , you just add window load event.
5th Jun 2018, 12:17 PM
Raj Chhatrala
Raj Chhatrala - avatar
+ 2
happy to help you
5th Jun 2018, 12:18 PM
Raj Chhatrala
Raj Chhatrala - avatar