By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,313 Members | 1,145 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,313 IT Pros & Developers. It's quick & easy.

style and disabled?

P: n/a
Is disabled to be set in the style of a tag just like visible? I am trying
to set the whole content of a td tag to disabled like this,
style='disabled:true' and it does not seem to work. Is this possible of is
disabled not to be set in style?
Nov 4 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Martin wrote:
Is disabled to be set in the style of a tag just like visible? I am trying
to set the whole content of a td tag to disabled like this,
style='disabled:true' and it does not seem to work. Is this possible of is
disabled not to be set in style?


It's actually an HTML question, but since you're here...

In the HTML 4 specification, 'disabled' is an attribute of button,
input, optgroup, option, select, and textarea elements. It can have two
values: true or false.

<URL:http://www.w3.org/TR/html4/interact/forms.html#adef-disabled>
It's value can be set in the HTML source (if set, the value is 'true'
and the element is disabled):

<input type="text" .... disabled>

Or by script:

<form ...>
<input type="text" name="textA">
<input type="button" value="Disable textA" onclick="
this.form.textA.disabled = true;
">
...
</form>
If set to 'true', the element is disabled. If set to false, it is
enabled (i.e. is is not disabled).

--
Rob
Nov 4 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.