Q:

How can we find the childnode element type in javascript?

I have a table cell and I would like to know if it has a text box inside or simply the span tag in it dynamically using javascrip? 

A:

If you want to check whether there's an <input> anywhere inside an element, you could use getElementsByTagName():
if (myTableCell.getElementsByTagName('input').length>=1) {
    ...do something with the input...
}

