Why is this ARGB hex not working?
<td style="background-color: #FFFF9980">
Why is this ARGB hex not working?
<td style="background-color: #FFFF9980">
Use rgba(255,153,128,1.0)
instead of your hex value (though if that really is ARGB it's the same as #ff9980
in RGB
- if you meant RGBA then you'll need rgba(255,255,153,0.5)
).
ARGB
. –
Samhita background-color
as evidenced by the sentence I really need this color
. I gave him a solution to that problem. –
Samhita ARGB
to RGBA
you are changing the question as they are totally different things. The solution when someone wants to add transparency to their colours is to use rgba(r,g,b,a)
. When someone asks Why is this not working?
they very often mean How can I make this work?
. –
Samhita the CSS3 spec says:
Unlike RGB values, there is no hexadecimal notation for an RGBA value.
so you will have to use the rgba(255,153,128,1.0)
mentioned above.
RGBA color values are an extension of RGB color values with an alpha channel - which specifies the opacity for a color.
An RGBA color value is specified with: rgba(red, green, blue, alpha). The alpha parameter is a number between 0.0 (fully transparent) and 1.0 (fully opaque).
<td style="background-color: rgba(255, 0, 0, 0.2);">
#p1 {background-color:rgba(255,0,0,0.3);}
#p2 {background-color:rgba(0,255,0,0.3);}
#p3 {background-color:rgba(0,0,255,0.3);}
#p4 {background-color:rgba(192,192,192,0.3);}
#p5 {background-color:rgba(255,255,0,0.3);}
#p6 {background-color:rgba(255,0,255,0.3);}
<h1>Define Colors With RGBA Values</h1>
<p id="p1">Red</p>
<p id="p2">Green</p>
<p id="p3">Blue</p>
<p id="p4">Grey</p>
<p id="p5">Yellow</p>
<p id="p6">Cerise</p>
© 2022 - 2024 — McMap. All rights reserved.
ffff99
with an alpha of80
or an rgb offf9980
and and alpha offf
? The bit packing is vital to figuring out what bytes are what, and what color that value represents. You can't just change the encoding and expect to get valid output. – Injure