On click of a button, if the 4th slide in a slider is currently active, I’d like to run a simple function (changing a text value). Here’s my code:
$(".button").on('click', function() {
if ($('.w-slide:eq(4)').hasAttribute("aria-hidden")) {
}
else {
$('.text').text("success").val();
}});
Anyone know why this isn’t working? Should be fairly straightforward but I’ve had no luck so far.