Here's the "almighty code"!
function testFun(target){
$(this).addClass("element")
$(target).addClass("target")
}
<a href="#" onclick="testFun('.class')" >Element</a>
<div class="class"> </div>
Briefly, upon the onClick event I want to modify the element too! I want to be able to use the same function in multiple situations. Please provide a solution to be able to do the above mentioned.