Im working on a form that I need to break in sections. example form.cfm?section=A, form.cfm?section=B and form.cfm?section=C. When employee access form.cfm?section=A, form.cfm?section=B and C need to be disable only section A will available for user to add input. when section B is accessed by supervisor section A and C are disable and when section C is accessed by VP both A and B are disabled. Is there a way to do this with a JavaScrip function?
var oFormElemb = document.forms.b.removeAttribute("disabled"); //enable element
var oFormElema = document.forms.a.setAttribute("disabled", "disabled"); //disable element
the reason you need "disabled" to equald "disabled" is that in HTML all that is required is the word,
i.e. <input name="a" type="text" disabled /> however, in XHTML (and to make IE happy) you need it to equal something, therefore the standard is to make it equal disabled.