Hello,
Somewhere in my code I have
<input TYPE="button" NAME="btnFirst" VALUE="<<" OnClick="GetFil e('1')"
DISABLED>
I changed the layout of the INPUT with a stylesheet to
INPUT {
color: #FFFFFF;
background: #000000;
text-shadow: none;
}
However, the 'shadow' of a disabled button is NOT removed.
How can I set the color of a disabled button to a custom color?
Is it possible to set a different color for the border and the text?
How can I apply these settings to only a BUTTON, and no other INPUT fields?
tia
bartp
--
=============== =============== ============
Hyper A.R.T.
bart plessers
Paul Van Ostaijenlaan 4
3001 Heverlee
BELGIUM
tel: +32 (16) 23.40.85
fax: +32 (16) 23.41.06
=============== =============== ============ 5 28568
bart plessers wrote: <input TYPE="button" ... DISABLED> INPUT { text-shadow: none; }
However, the 'shadow' of a disabled button is NOT removed.
(a) text-shadow has no (AFAIK) browser support
(b) that isn't a shadow, its a border
How can I set the color of a disabled button to a custom color?
input[disabled] { color: #faa; }*
Is it possible to set a different color for the border and the text? How can I apply these settings to only a BUTTON, and no other INPUT fields?
input[type=button] {}*
* MSIE doesn't support attribute selectors. If you care about this behind
the times browser you have to use classes instead.
--
David Dorward http://dorward.me.uk/
> * MSIE doesn't support attribute selectors. If you care about this behind the times browser you have to use classes instead.
what do you mean by this?
Currently I use
<TAG class="mystyle" > qsdfqsdf </TAG>
where mystyle is defined in a stylesheet like:
..mystyle {.....}
Here is my sample HTML
+++++++++++++++ +++++++++++++++ ++++++++++
<input TYPE="button" NAME="btnFirst" VALUE="<<" OnClick="GetFil e('1')"
DISABLED class="MyButton ">
<input TYPE="button" NAME="btnPrevio us" VALUE="<" OnClick="GetFil e('-11')"
DISABLED class="MyButton ">
<input TYPE="button" NAME="btnClose" VALUE="#" OnClick="GetTab le('1')"
class="MyButton ">
<input TYPE="button" NAME="btnNext" VALUE=">" OnClick="GetFil e('13')"
class="MyButton ">
<input TYPE="button" NAME="btnLast" VALUE=">>" OnClick="GetFil e('24')"
class="MyButton ">
+++++++++++++++ +++++++++++++++ ++++++++++
And my stylesheet
+++++++++++++++ +++++++++++++++ ++++++++++
INPUT[type=button] {background: Green;}
INPUT[disabled] {background: Lime;}
..MyButton {background: Maroon;}
..MyButton[disabled] {background: Red;}
+++++++++++++++ +++++++++++++++ ++++++++++
On Internet Explorer, the class MyButton is displayed, but no difference is
made between 'enabled' and 'disabled', all the buttons are "Maroon"
On Netscape Navigator,
enabled buttons are 'Green' (from INPUT), disabled are 'Red' (from
class="MyButton " )
On Opera
enabled buttons are 'Green' (from INPUT), disabled are 'Red' (from
class="MyButton " )
Do you have any about those inconsistencies ?
It seems to me that styles for tags and styles for classes are mixed...
Do you have a tip how to
- have different styles for enabled/disabled buttons in MSIE (without the
need to assign different classes)
- have a consistent layout in MSIE, Navigator and opera (and other...)?
thanx in advance,
bartp
--
HyperART
Paul Van Ostaijenlaan 4
3001 Heverlee
"David Dorward" <do*****@yahoo. com> wrote in message
news:bm******** ***********@new s.demon.co.uk.. . bart plessers wrote:
<input TYPE="button" ... DISABLED> INPUT { text-shadow: none; }
However, the 'shadow' of a disabled button is NOT removed.
(a) text-shadow has no (AFAIK) browser support (b) that isn't a shadow, its a border
How can I set the color of a disabled button to a custom color?
input[disabled] { color: #faa; }*
Is it possible to set a different color for the border and the text? How can I apply these settings to only a BUTTON, and no other INPUT fields?
input[type=button] {}*
* MSIE doesn't support attribute selectors. If you care about this behind the times browser you have to use classes instead.
-- David Dorward http://dorward.me.uk/
Bart Plessers (artabel) wrote: * MSIE doesn't support attribute selectors. If you care about this behind the times browser you have to use classes instead. what do you mean by this? Currently I use <TAG class="mystyle" > qsdfqsdf </TAG>
where mystyle is defined in a stylesheet like:
.mystyle {.....}
Yes, this is a class selector
<http://www.w3.org/TR/CSS21/selector.html#c lass-html>.
<...>
And my stylesheet +++++++++++++++ +++++++++++++++ ++++++++++ INPUT[type=button] {background: Green;} INPUT[disabled] {background: Lime;} ..MyButton {background: Maroon;} ..MyButton[disabled] {background: Red;} +++++++++++++++ +++++++++++++++ ++++++++++
These ([attr=val]) are attribute selectors
<http://www.w3.org/TR/CSS21/selector.html#a ttribute-selectors> which
are not supported in IE.
On Internet Explorer, the class MyButton is displayed, but no difference is made between 'enabled' and 'disabled', all the buttons are "Maroon"
<...>
Do you have any about those inconsistencies ? It seems to me that styles for tags and styles for classes are mixed...
What do you mean "... are mixed"?
Do you have a tip how to - have different styles for enabled/disabled buttons in MSIE (without the need to assign different classes)
AFAIK, no way. You may try some of the groups on the
msnews.microsof t.com server or browse/search the MSDN Library
<http://msdn.microsoft. com/library>.
- have a consistent layout in MSIE, Navigator and opera (and other...)?
Experiment, see what works, where, and find/search for specific
issue (when you enconter such) workarounds - you may ask in the groups.
--
Stanimir
>What do you mean "... are mixed"?
Well, I my example, for NetScape:
HTML
+++++++++++++++ +++++++++++++++ ++++++++++
<input TYPE="button" NAME="btn1" VALUE="<<" DISABLED class="MyButton ">
<input TYPE="button" NAME="btn2" VALUE="<<" class="MyButton ">
+++++++++++++++ +++++++++++++++ ++++++++++
StyleSheet
+++++++++++++++ +++++++++++++++ ++++++++++
INPUT[type=button] {background: Green;}
INPUT[disabled] {background: Lime;}
..MyButton {background: Maroon;}
..MyButton[disabled] {background: Red;}
+++++++++++++++ +++++++++++++++ ++++++++++
btn1 becomes red ->> settings from .MyButton definition
btn2 becomes green ->> settings from INPUT definition --> NOT logic
In my opinion, btn2 should becom Maroon, because
- it has class MyButton
- it is enabled
so it should have definition of .MyButton (maroon) and NOT definition of
INPUT (green)
Definitions are 'mixed' here.
any idea?
tia
bartp
--
HyperART
Paul Van Ostaijenlaan 4
3001 Heverlee
"Stanimir Stamenkov" <s7****@netscap e.net> wrote in message
news:bm******** ****@ID-207379.news.uni-berlin.de... Bart Plessers (artabel) wrote:
* MSIE doesn't support attribute selectors. If you care about this
behind the times browser you have to use classes instead.
what do you mean by this? Currently I use <TAG class="mystyle" > qsdfqsdf </TAG>
where mystyle is defined in a stylesheet like:
.mystyle {.....}
Yes, this is a class selector <http://www.w3.org/TR/CSS21/selector.html#c lass-html>.
<...>
And my stylesheet +++++++++++++++ +++++++++++++++ ++++++++++ INPUT[type=button] {background: Green;} INPUT[disabled] {background: Lime;} ..MyButton {background: Maroon;} ..MyButton[disabled] {background: Red;} +++++++++++++++ +++++++++++++++ ++++++++++
These ([attr=val]) are attribute selectors <http://www.w3.org/TR/CSS21/selector.html#a ttribute-selectors> which are not supported in IE.
On Internet Explorer, the class MyButton is displayed, but no difference
is made between 'enabled' and 'disabled', all the buttons are "Maroon"
<...>
Do you have any about those inconsistencies ? It seems to me that styles for tags and styles for classes are mixed...
What do you mean "... are mixed"?
Do you have a tip how to - have different styles for enabled/disabled buttons in MSIE (without
the need to assign different classes)
AFAIK, no way. You may try some of the groups on the msnews.microsof t.com server or browse/search the MSDN Library <http://msdn.microsoft. com/library>.
- have a consistent layout in MSIE, Navigator and opera (and other...)?
Experiment, see what works, where, and find/search for specific issue (when you enconter such) workarounds - you may ask in the groups.
-- Stanimir
Sorry for the large quote. See my comment bellow.
Bart Plessers (artabel) wrote: What do you mean "... are mixed"?
HTML +++++++++++++++ +++++++++++++++ ++++++++++ <input TYPE="button" NAME="btn1" VALUE="<<" DISABLED class="MyButton "> <input TYPE="button" NAME="btn2" VALUE="<<" class="MyButton "> +++++++++++++++ +++++++++++++++ ++++++++++
StyleSheet +++++++++++++++ +++++++++++++++ ++++++++++ INPUT[type=button] {background: Green;} INPUT[disabled] {background: Lime;} ..MyButton {background: Maroon;} ..MyButton[disabled] {background: Red;} +++++++++++++++ +++++++++++++++ ++++++++++
btn1 becomes red ->> settings from .MyButton definition btn2 becomes green ->> settings from INPUT definition --> NOT logic
In my opinion, btn2 should becom Maroon, because - it has class MyButton - it is enabled
so it should have definition of .MyButton (maroon) and NOT definition of INPUT (green)
Definitions are 'mixed' here.
This is related to the selector's specificity
<http://www.w3.org/TR/CSS21/cascade.html#sp ecificity>. If two
selectors have equal specificity you could change their order of
appearance but in your case:
..MyButton {background: Maroon;}
..MyButton[disabled] {background: Red;}
The second selector has higher specificity so it doesn't matter if
you change the order.
--
Stanimir This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: JohnSouth |
last post by:
Hi I've an image submit button on a form that needs to appear flat on
the surface. I can't get rid of the shadow that appears bottom and
right.
This is the best I can do.
<code>
..SearchButton
{
width=100;
|
by: multimatum2 |
last post by:
Hello,
I need to enable/disable input text forms...
But...
I need to have the same style (color...) in both modes..
Could you help me ?
Thanx a lot
A small sample...
<HTML><HEAD><TITLE></TITLE></HEAD>
|
by: Chris S |
last post by:
I've been unsuccessfully attempting to write a method in Javascript to
change an input field from TEXT to SELECT when a user selects (or
unselects) a radio button. In my frustration I have been searching the
web but have also come up empty handed on any documentation that
discribes how to do this. Is what I'm trying to do just not possible??
Thanks,
Chris S.
|
by: petermonsson |
last post by:
Hi all,
Does IE support disabled for the Image type in inputs? This small
example doesn't seem to work when the type is Image, but perfectly fine
when the type is submit.
Best Regards
<html>
<head>
|
by: Mike |
last post by:
I have a form that contains 240 "products". Each Product has a TR. Each TR
contains a Yes and No radio button and a Product-Qty text input.
A situation exists where I have to go through all the products and check the
No radio button for all the products. In javascript, that is easy enough.
When the No radio button is clicked, I have to put '0' in the Product-Qty
text input, and disable the Product-Qty text input. I create an array of...
| |
by: pbearne |
last post by:
Hi guys
I am trying to this function below
I have a web form with a load of inputs text boxs etc and i need to
disable them
So I have tried to write a function I can call and get the function to
work the type of the input so can disaable as needed
|
by: Romulo NF |
last post by:
Greetings again to everyone,
Im back to show this grid componenet i´ve developed. With this grid you can show the data like a normal table, remove the rows that you need, add rows, import data, call determined functions, and edit the data already present
What will you need to use the grid? A table with standard markup and an ID to call the script that will turn the table into a grid
Parameters:
tabelaID => id of the table that will...
|
by: The Devil |
last post by:
Hi,
This is not just a simple input form made with javascript. This is the code:
<html><head>
<script language="JavaScript">
var i=0;
function add(inputEvent, inputDur, inputCode, placeEvent, placeDur, placeCode, placeDel, elmnt, inputButton) {
|
by: Allen Chen [MSFT] |
last post by:
Hi Richard,
Quote from Richard==================================================
However I also want to be able to remove the
panes. I have tried to include this, but find that when I first add the
pane
the remove event does not get handled, though thereafter it is handled
without problems.
==================================================
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |