Colour gradient backgrounds.


    Would it be possible to introduce a style definition for displaying a
colour gradient as the background for an element?

    For example to provide a background that is black towards the top and
which fades through the intervening shades of grey to reach white at the

    I know this can be accomplished using images, but feel this lacks
liquidity for accessibility. It could also be accomplished by implementing a
series of <div> elements, each with an ID that defines an incrementally
lighter colour for the background and then overlaying the "content" on top
with z-indexing and absolute positioning, but suspect that a more simple
solution would be desireable.

    Perhaps the definition could be something along the lines of:

background-gradient: #000000 #ffffff top

    where the first number is the start colour, the second is the end colour
and the position (top) would be the aspect of the element the gradient would
begin from.

    I'm aware that the combined knowledge and expertise on this list is
considerable compared to my own, so please accept my apologies if this
suggestion is misplaced or unreasonable.


Léonie Watson  |  Accessibility Consultant.
T. +44 (0)117 344 5012

Visit our website today:

Received on Monday, 10 May 2004 09:12:17 UTC