Not off the mark at all, hydrurga. My first thought on reading the post was that the form does exactly what it's programmed to do.
I'm not a big fan of "automatically" submitting forms. A form should have a "Go" button
Code:
<input type="submit" value="Submit">
to cause the action. Note that this won't require any javascript coding. Clicking on the Submit will action the form.
There are challenges in mixing radio buttons
OR text input, tho. radio buttons cause a "select only one" function automatically. Adding the text input allows the user to choose one of the pre-filled options
and enter a directory.
Suggest using a drop-down list box instead of radio buttons, with three options:
Code:
<select name="photo">
<option value="">-- Select One --</option>
<option value="pana">PANASONIC DCM-215</option>
<option value="canon">CANON SD 1000</option>
<option value="base">Enter Base Directory To Access Photos</option>
</select>
Then only use the text in the <input type="text" id="inputDir"> if the "Enter Base Directory..." (photo = base) is selected. Otherwise, simply ignore anything in that field.
One would probably need to validate that something
is in the field if base is selected.
Just a thought.