Im trying to change a sibling of a div element and this is the statement i used
$('.edit').click(function(){
this.siblings('.innerInfo').html("success");
});
It keeps throwing the <HTMLDivElement> has no method 'siblings'
exception, and i really cant figure out why. I've initiated jQuery and ive started the script on document.ready
thanks for your help!
Use $(this)
instead of this
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With