I want to be able to get ANY element's html code when I click on it. So far I can only get text elements but I can't get image elements. Here's what I have :
$(document).click(function(event) {
alert($(event.target).html());
});
this doesn't work with images tags like
<img src="" alt=""/>
but only with text ..
Can you please tell me how to proceed to get the images element ?
Thanks in advance.