When I'm disabling a
<select name="sel" disabled>
<option>123</option>
</select>
element, it doesnt pass its variable.
What to do to look it like disabled, but be in "normal" state?
This is because I have a list of "selects", and sometimes some of them have single value, so user should understand that it has only one value without clicking it.
My solution was to create a disabled class in CSS:
and then your select would be:
The user would be unable to pick any values but the select value would still be passed on form submission.
Wow, I had the same problem, but a line of code resolved my problem. I wrote
I send the form to a php script then it prints the correct value for each options while it was "null" before.
Tell me if this works out. I wonder if this only works on mine somehow.