Connecting Tech Pros Worldwide Help | Site Map

style and disabled?

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 4th, 2005, 03:56 AM
Martin
Guest
 
Posts: n/a
Default style and disabled?

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?



  #2  
Old November 4th, 2005, 06:05 AM
RobG
Guest
 
Posts: n/a
Default Re: style and disabled?

Martin wrote:[color=blue]
> 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?[/color]

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
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,989 network members.