javascript - Jquery find: Uncaught TypeError: row.find is not a function -


i have table:

<tbody class="schoolsrows">     <tr>         <td width="50%">             <input type="text" class="classa schoolnameclass valid" id="1">         </td>         <td width="25%">             <input type="text" class="classa postcodeclass valid" id="2">         </td>         <td width="25%">             <input type="text" class="classa urnclass valid" id="3">         </td>         <td>             <input type="button" value="clear content" onclick="clearrowcontent(this)">         </td>     </tr> </tbody> 

on button click, trying reach each of textboxes , clear it.

here javascript code:

function clearrowcontent(e) {     var row = e.closest('tr');     var textboxtoclear = row.find('.schoolnameclass'); } 

i can row, problem when try textboxes using find or siblings error

uncaught typeerror: row.find not function

i wonder why happening.

bind e java script jquery object , $(e)

var row = $(e).closest('tr'); 

Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - Bypass Geo Redirect for specific directories -

php - .htaccess mod_rewrite for dynamic url which has domain names -