I'm trying to make a function that will target multiple divs, one at a time depending on a variable. So if they click the button once it will show the tip with ID of #tip1, if they click it again, it will show #tip2 etc.
<script>
var tipCount = 0;
$('.subtitle').click({
function () ({
$('#tip'+tipCount++).toggleClass('visible');
});
});
</script>
I've been google for well over an hour and just can't get it it to work!