[Javascript] How to prevent user from selecting in select box

Håkan Magnusson hakan at backbase.com
Wed Mar 31 07:03:15 CST 2004


Try setting it to readonly instead of disabled.

Regards,
H

Antony Paul wrote:

> Hi all,
>     I have a select box which is dynamically generated for editing the data.
> Based on a condition it has to be disabled. If I use the disabled attribute
> it won't submit the value of the select box and I have to display the data.
> I tried onfocus and onclick. But it is not working. Any solutions will be
> appreciated. I need some way to avert the selection.
> 
> Antony Paul
> 
> _______________________________________________
> Javascript mailing list
> Javascript at LaTech.edu
> https://lists.LaTech.edu/mailman/listinfo/javascript
> 
> 



More information about the Javascript mailing list