[jQuery] checking if there is a select in the form/html?

[jQuery] checking if there is a select in the form/html?


Hi,
I have this:
var state = $("select[@name='state']").get(0).value;
but there are times there is no select element in the html, and cause
this statement to fail,
how to check if there is 'select[@name='state']' present in the html?
Thanks,
Angelo