Dynamically created ImageMap: How to use the click event in already binded script.
Hi,
I am not sure if there exeist a solution for my problem. I use a jquery script (application.js) which I bind in with my index.html. Somewhere in my code I insert a html image map via .html(imagemap-html-code) . I want to make use of the click event of the image map in my application.js. I already tried to use the .on:
$("area").on("click", function(){
alert($(this).attr("alt"));
});
But it did not work. Am I missing something? Or is it simply not possible?
Thank you very much.
Olaf