Link to source code:
https://codepen.io/dcode-software/pen/NEErgO
Page Loaders like this are a common trend nowadays on websites, especially commercial ones. In this video we look at how to make a custom one from scratch – it’s actually quite simple which you’ll see as I guide you through it.
It’s as simple as creating a wrapper, setting an animation and then triggering the animation with Javascript once the page finishes loading. The best part? It’s pure HTML, CSS & Javascript. No jQuery or external libraries are required to achieve this effect.
0:00 Overview
0:32 Adding HTML and images
2:22 Writing the CSS
6:29 Writing the JavaScript
9:05 Wrapping up
Follow me on Twitter @dcode!
If this video helped you out and you’d like to see more, make sure to leave a like and subscribe to dcode!
#dcode #javascript #css
source
Thank you sir
Hey there, I'm having an issue with when the user hits the back button on the next page, the loader doesn't disappear. As of right now I have the loader unhiding when the user hits a submit button.
Thank you! 🥰
thanks mate
BUILD CARD GAME USING HTML CSS AND JAVASCRIPT
https://youtu.be/idKCUPzrnm4
This did not work for me for some reason. It stays on for a second and then disappears. It does not wait for the page to load completely. I did everything that you did so I'm a little confused here.
Great tutorial! How would you make this work on an iframe.
hey is there a way i can make it wait a couple seconds before fading out?
many thanks for sharing.
the only limitation is the square background of the gif file, this is another reason why it's better to work with svg files.
but I don't know how to animate svg files.
Thank You 🤗
Thank you for the video. I searched a whole night. Arround 12 hours, to make a loading animation. And your video saved me.He helped me understand how to do it and it worked. Thx for the video
A lot helpful ! Thank you.
Suggestion : Inside the keyframes fadeout also add z-index = -1. Otherwise, the other elements won't be clickable.
Finally found a working and easier to understand code, thanks!
In subtitles his name is pronounced as 'DOM' 😅
This is awesome. Thank you.
Thanks
Is this applicable for the anchor tag button with link to other page
Спасибо большое! Thank you so much!
Hi can you used internet connection to load. The image or information.
WTF!!!
What a useless feature! Why would anyone need their website to load slower, to just show off a LOADER gif!!!
Besides, you are missing out on async-await world of JS completely! A Totally bad practice.
I really didn't like the way you explain stuff. But your tutorials awesome and really helpful!!
thanks!
Thank you so much for this!!!!!
Thank you so much for this
This is legit man!
I used this because my websites background image loads slowly
Please
Please sir reply
Sir I beg u sir…please reply me…it's very urgent …loader got suucessfully run…but it is coming and going very fast sir….and we also cant tell to client , that slow down your browser to 3g…so please reply me…..where to add command for making it appear for at least 3 sec on page
Great explanation man!
You explain very well. Love your videos!
Great tutorial
<3 Ly
8:17
What is YouTube.local?
Love this!
Satisfying keyboard sound😴😴
Thanks a lot you make me very easy way 😍
Thank you solved my problem
Thanks a lot bro, But I'm not seeing anything while the page is loading. After looking at the console it only prints the data class = "loader hidden" at the end of load
I took this one step further to use it as a "IsBusy" indicator for ASP.NET Core MVC:
…
<div class="form-group">
<input type="submit" value="Save" id="btnSave" class="btn btn-primary" onclick="showIsBusy()" />
<input type="button" value="Cancel" id="btnCancel" onclick="history.go(-1)" class="btn" />
</div>
</form>
</div>
</div>
<div class="isbusy" id="isbusy">
<img src="~/images/IsBusy.gif" alt="Processing…"/>
</div>
<script>
$(document).ready(function () {
$("#isbusy").hide();
});
function showIsBusy() {
//alert("isBusy");
$("#isbusy").show();
$("form").submit();
}
</script>
Which editor you used in this video
how to add time to loader