How to check image loaded or not in JQuery?

Today now in this post i will share with you How to check image loaded or not in JQuery? Sometimes on our project we need to detect upload image 100% load successfully, for this example if you want to do print any text instead of image before load image. So we can do this by using jquery load and error method. We can see in the bellow example:


<script type="text/javascript">
		console.log("Now loaded correctly");
		console.log("Found Error in loading image");

Read Also : How to convert Object into Array in PHP?

Thanks for read. I hope it help you. For more you can follow us on facebook.


About Shahriar Sagor

My name is Shahriar sagor. I'm a developer. I live in Bangladesh and I love to write tutorials and tips that will help to other Developer's. I am a big fan of PHP, Javascript, JQuery, Laravel, Codeigniter, VueJS, AngularJS and Bootstrap from the early stage.

View all posts by Shahriar Sagor →