function eventlisteOnclick(_class, ability, _src, _id){
var cell_onclick = document.querySelectorAll(_class);
for(var c = 0; c < cell_onclick.length; c++){
cell_onclick[c].addEventListener('click', function(){
//problem here , ability(_src) = fun1(mysrc);
//error
ability(_src);
}, false);
}
}
function fun1(mysrc){
console.log();
}
eventlisteOnclick("abc", "fun1", "this.src", null);
the fun1 is a function and i was trying to set as variable at eventlisterOnclick , and run the function there , but when i type ability(_src); it wont work. how do i set the function in my eventlisteOnclick.
