Answers for "jquery pass element to function"

1

jquery pass element to function

// use 'this'
$("button").click(function() {
    $(this).css("background-color", "red")
})
Posted by: Guest on March-17-2021

Code answers related to "jquery pass element to function"

Code answers related to "Javascript"

Browse Popular Code Answers by Language