[Javascript] making <select> tags read only
Rodney Myers
rodney at aflyingstart.net
Wed May 16 03:02:29 CDT 2001
Andrew,
I suppose that you mean that you set the select option and do not want
the user to change that.
If the setting of the selected option is represented by :
function setForm(form){
form.List3.selectedIndex=X; // X is a var set somehow
}
<SELECT NAME="List3" onchange="readOnlyElement(this)">
function readOnlyElement(Elem){
alert("This is read only");
setForm(Elem.form);
}
hth
Rodney
Andrew Dunn wrote:
> How would you make a items in a select tag read only? i've tried onFocus
> = "this.blur();", but it doesn't seem to work. Can anyone advise?
>
--
Shop at ssistant Add-ons and Developer Workshops
http://www.aflyingstart.net/addons/
Enquiries regarding Shop at ssistant Classic training :
Call 01256 880770
Rodney Myers
Based in Oxford, England
Technical Director, Shop at ssistant eCommerce Solutions
More information about the Javascript
mailing list