I've wrote this code seems correct but appear this error :
Uncaught ReferenceError: show is not defined
This is my simple code:
(function ($) {
$(document).ready
(
function () {
$('.mapban').parent().jclip(0, 0, 1060, 750);
$('#mapplane').draggable();
$('#mapplane > div ').css( 'display', 'none' );
$('.button').attr('onclick','show(this)');
function show(button){
alert(button);
}
}
)
})(jQuery)
onclickattribute with jQuery?! You have easy access to the right way to do this (attaching non-exclusive event handlers).