You could do something like the following:
HTML Code:
<html>
<body>
<script language="javascript" type="text/javascript">
options = {
0: {"protected": true, "name": "Option 1"},
1: {"protected": false, "name": "Option 2"}
};
var myFunction = function(obj) {
if(options[obj.selectedIndex]["protected"]) {
alert("Protected!");
} else {
alert("Unprotected!");
}
};
</script>
<select id="one" name="one" onchange="myFunction(this);">
<option>Option 1</option>
<option>Option 2</option>
</select>
</body>
</html>
That's the general principle at least.
Bookmarks