Domanda

I've found a lot of sites that explain that an IE gradient should be made using:

.IEGradient {
    filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#AAAAAA', endColorstr='#BBBBBB');
}

but since I would need to be able to accept the direct input of colours by users, I'd like to know if these *Colorstrs are limited to just the #RRGGBB format, or if other formats such as #RGB or rgb(r, g, b) etc. would also work. I've tried googling for answers, but I couldn't find any site saying the long HEX format was required, but I just kept finding more and more sites that all just used the long hex format, and none that used any other formats, so that made me wonder.

By the way, msdn says #AARRGGBB format is required, yet there are enough sites that don't include the AA part, so that still makes me wonder if other formats would work, if the format that isn't mentioned on msdn also works.

È stato utile?

Soluzione

I've just found the emulation tab in IE11's dev tools, and apparently you can emulate down to IE5 there. It turns out that indeed only the #AARRGGBB and #RRGGBB formats are allowed. Any other format causes it to render a blue-to-black gradient.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top