SoFunction
Updated on 2025-04-03

Only the onload event will be executed if the img element is not added to the document after it is created


<!DOCTYPE HTML>
<HTML>
<HEAD>
<meta charset="utf-8" />
<title>Onload event will be executed after the img element is created but not added to the document</title>
</HEAD>
<BODY>
<script>
var img = ('img');
= "/rny/sinamail57/skins/110318/17/";
= function(){alert();};
</script>
</BODY>
</HTML>