Categories
Development

Unable to use .find() to get value from table/form

Trying to wrap my head around this for a while now. Some guru needs to help me out, it would be greatly appreciated. I don’t know why it is not working. $(“.form”).on(‘submit’, function(event) { event.preventDefault(); //prevent the forms default action var surname = $(this).find(“.surname”); console.log(surname); }); <script src=”https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js”></script> <table> <form class=”form” method=”post” action=”nextpage.php”> <tr> <td […]