JavaScript - overwriting .onload prototype of HTMLImageElement(s)
<p>Is it possible to bind an <strong>onload</strong> event to each image, declaring it once? I tried, but can't manage to get it working... (this error is thrown: <em>Uncaught TypeError: Illegal invocation</em>)</p>

<pre><code>HTMLImageElement.prototype.onload = function()
{
        console.log(this, "loaded");
};
</code></pre>

<p>P.S: I also tried returning <em>this</em>, but doesn't seem to be the issue here... any suggestions / explanations on why my current code isn't working?</p>