Forum Moderators: open
<form>
<select>
<option value="x">Option X</option>
</select>
</form>
<script>
document.write(document.form.select.value);
</script>
Basically, I want to have a document.form.select.another_value so that one option can pass more than one value for Javascript to play with.
Presumably this is fairly easy to do, but as I've never needed it before it's something I've never worried about.
Thanks.
<option value_one="x" value_two="y">Option X and Y</option>
document.do_one_thing(document.form.select.value_one);
document.do_some_other_thing(document.form.select.value_two);
Selecting one option gives me two separate values to do different things to.
If it helps, I can post my script as it is so far.
Much appreciated.
James.
[pageresource.com...]
Thanks DrDoc for all your help.
-- James