Skip navigation
Currently Being Moderated

disabled property does not work in IE

May 9, 2012 7:15 AM

I want to disable the box from the option in the menu, not the select itself.

This code is worked on FF but not on IE.  Is there the way to have the option disable work on IE? or make it ready only?

  i also try to change the gray color from the disable using css but still not work on IE:

<select name="re">

<cfloop query="qry">

<option value="#qry.re_id#" disabled >#qry.re_name#

</option>

</cfloop>

</select>

 

thanks

 

kt

 
Replies
  • Currently Being Moderated
    May 10, 2012 10:49 AM   in reply to kt03

    First, you are not using the correct syntax to disable your options.  A google search on "html input disable" will lead you to the correct syntax.

     

    Next, you say that you do not want to disable the select, but you are attempting to disable all the options.  That seems very odd.

     
    |
    Mark as:
  • Currently Being Moderated
    May 15, 2012 1:25 AM   in reply to kt03

    As Dan says, be aware that the loop implies each option element will have a disabled attribute. Since you have to output, use the cfoutput loop (update: unless, of course, the code you've shown is already within the cfoutput tag):

     

    <select name="re">

    <cfoutput query="qry">

    <option value="#qry.re_id#" disabled >#qry.re_name#

    </option>

    </cfoutput>

    </select>

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points