Something I have to be doing wrong but I do not see what. I have a list of divs and I want them to click on an item in the list to take their id. I currently have this but I can not get it to work.
(function($) {
function selectParams() {
$(this).click(function(){
var id = $(this).attr("id");
console.log(id);
});
}
})(jQuery);
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div class="first-column" id="first-column">
<li id="WE"><div><span>WERK</span></div></li>
<li id="OU"><div><span>OUTER</span></div></li>
<li id="IN"><div><span>INTRA</span></div></li>
</div>