Remove Value

Remove Value

I need a way to delete a select field (make it undefined, or whatever the default is if a select does not exist). So, if I had something like:

<select id='test' onchange='alert(test.value); functiontodeleteselecthere(); alert(test.value);'>
<option value='1'>1</option>
<option value='2'>2</option>
</select>


This would display the selected value first (using alert();) then delete the select, then attempt to display the value again (this time it should be undefined).

Is there a way to do this?