[TYPO3-core] RFC #14788: Add fallback graphics for CSS3 background gradients

Steffen Gebert steffen at steffen-gebert.de
Sat Jun 19 14:19:55 CEST 2010


Hi,

This is a SVN patch request.

Type: Bugfix

Bugtracker references:
http://bugs.typo3.org/view.php?id=14788

Branches:
trunk

Problem:
We currently use CSS3 gradients in some places:
> background-image: linear-gradient(center top, #ffffff 0px, #ececec  
> 100px);
> background-image: -moz-linear-gradient(center top, #ffffff 0px, #ececec  
> 100px);
> background-image: -webkit-gradient(linear, 0% 0%, 0% 100%,  
> color-stop(0px, #ffffff), color-stop(100px, #ececec));

For browsers like IE or Opera, which cannot deal with gradients, the  
defined background-color is used.

Solution:
A better fallback is to define the gradient as graphic (url(..)) at the  
first place and then follow with the (-moz|-webkit)linear-gradient  
definitions.

* Incompatible browsers will ignore the gradient definition and load the  
image file
* Compatible browser will ignore the file (and thus spent HTTP requests),  
but show the gradient as defined in CSS.

Note:
Color profiles of all files have been removed using pngcrush (#14516)

Steffen
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 14788.diff
Type: text/x-diff
Size: 8295 bytes
Desc: not available
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20100619/823aabc3/attachment.diff>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 14788.zip
Type: application/zip
Size: 5631 bytes
Desc: not available
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20100619/823aabc3/attachment.zip>


More information about the TYPO3-team-core mailing list