Hi every one i am new to JQuery.i have a problem with click event.i am taken temearea_div
as a container when ever rightclick
passing an argument(classname) with that clearfunction is executed and copy Html content into tempaarea_div
.i had a problem while click a class with specific index. click is not identifying.could any one solve my problem. how to give selector to identify click with specific index.thanks in advance
THis is My Html Code
<div class="temparea_div">
<img src="img/Img_01.png"/>
</div>
<div class="Maintain_submenu_nav_02" style="display: none;">
<div class="maintainence_image_02"></div>
<div class="maintainence_image_02" style=" left: 22.2%;top: 32.7%;"></div>
<div class="maintainence_image_02" style="top: 35.7%;top:42.7%"></div>
<div class="maintainence_image_02" style="top: 35.7%;top:53.7%"></div>
<img src="img/Img_02.png"/>
</div>
My JQuery Code
$('.rightclick').bind(function(){
clearfunction('Maintain_submenu_nav_02');
});
var clearfunction=function(e){
$(".temparea_div").empty();
$('.'+e).show();
$(".temparea_div").html($('.'+e).html());
$('.'+e).hide();
};
this is not identidentiding click
$('.maintainence_image_02:eq(1)').bind('click', function() {
$('.maintainence_image_02:eq(1)').css("border", "1px solid #00FFFF");
maintaincesubmenu = true;
});
i used this one but when click temparea_div then .maintainence_image_02:eq(1) calling
$('.temparea_div').bind('click','.maintainence_image_02:eq(1)', function() {
$('.maintainence_image_02:eq(1)').css("border", "1px solid #00FFFF");
maintaincesubmenu = true;
});