অনরর HTML এ একটি ত্রুটি ঘটলে ইভেন্ট ট্রিগার হয়। আপনি অনরর বাস্তবায়ন করতে নিম্নলিখিত কোড চালানোর চেষ্টা করতে পারেন ইভেন্ট অ্যাট্রিবিউট -
উদাহরণ
<!DOCTYPE html>
<html>
<body>
<img src = "new.png" onerror = "display()">
<p>Alert would be visible, if the image isn't loaded correctly.</p>
<script>
function display() {
alert("Image load unsuccessful.");
}
</script>
</body>
</html>