Check if element is an input or a textarea